// Sub performs a̅ - b̅. a̅ will be clobbered
960922
func Sub(a, b []float32) {
	if len(a) != len(b) {
		panic("vectors must be the same length")
	}
	subAsm(a, b)
}
789719
func (s *Stats) Sub(other *Stats) Stats {
	if other == nil {
		return *s
	}
	var diff Stats
	diff.FreePageN = s.FreePageN
	diff.PendingPageN = s.PendingPageN
	diff.FreeAlloc = s.FreeAlloc
	diff.FreelistInuse = s.FreelistInuse
	diff.TxN = s.TxN - other.TxN
	diff.TxStats = s.TxStats.Sub(&other.TxStats)
	return diff
}
933546
func (c *Client) Subscribe(ctx context.Context, req *SubscriptionRequest) (string, error) {
	c.subscriptions.add(req)
	err := c.asynchronous.Send(ctx, req)
	if err != nil {
		// propagate send error
		return "", err
	}
	return req.SubID, nil
}
217695
func (ns *Namespace) Sub(a, b interface{}) (interface{}, error) {
	return _math.DoArithmetic(a, b, '-')
}
208133
func (es *EventSystem) subscribe(sub *subscription) *Subscription {
	es.install <- sub
	<-sub.installed
	return &Subscription{ID: sub.id, f: sub, es: es}
}
1317881
func (r *Router) Sub(path string) *SubRouter {
	return &SubRouter{
		prefix:   path,
		parent:   r,
		prefixes: []string{path},
	}
}
378413
func Sub(a, b *T) T {
	if a[3] == b[3] {
		return T{a[0] - b[0], a[1] - b[1], a[2] - b[2], 1}
	} else {
		a3 := a.Vec3DividedByW()
		b3 := b.Vec3DividedByW()
		return T{a3[0] - b3[0], a3[1] - b3[1], a3[2] - b3[2], 1}
	}
}
1264815
func (m *MockGauge) Sub(arg0 float64) {
	m.ctrl.Call(m, "Sub", arg0)
}
1090877
func Sub(r1, r2 ResourceTuple) (res ResourceTuple) {
	res.Cores = r1.Cores - r2.Cores
	res.Memory = r1.Memory - r2.Memory
	res.Disk = r1.Disk - r2.Disk
	return
}
462456
func enforceSingleSub(regexp *syntax.Regexp) error {
	if len(regexp.Sub) != 1 {
		return generatorError(nil,
			"%s expected 1 sub-expression, but got %d: %s", opToString(regexp.Op), len(regexp.Sub), regexp)
	}
	return nil
}
725329
func (o Timestamp) Sub(duration time.Duration) Timestamp {
	return o - Timestamp(duration/100)
}
102748
func (q1 Quat) Sub(q2 Quat) Quat {
	return Quat{q1.W - q2.W, q1.V.Sub(q2.V)}
}
930167
func (ss *FileSubStore) DeleteSub(subid uint64) error {
	ss.Lock()
	ss.delSub.ID = subid
	err := ss.writeRecord(nil, subRecDel, &ss.delSub)
	// Even if there is an error, continue with cleanup. If later
	// a compact is successful, the sub won't be present in the compacted file.
	if si, exists := ss.subs[subid]; exists {
		s := si.(*subscription)
		delete(ss.subs, subid)
		// writeRecord has already accounted for the count of the
		// delete record. We add to this the number of pending messages
		ss.delRecs += len(s.seqnos)
		// Check if this triggers a need for compaction
		if ss.shouldCompact() {
			ss.fm.closeFileIfOpened(ss.file)
			ss.compact(ss.file.name)
		}
	}
	ss.Unlock()
	return err
}
668312
func (t Time) Sub(o Time) time.Duration {
	return time.Duration(t-o) * minimumTick
}
1094086
func (m1 Mat3x2) Sub(m2 Mat3x2) Mat3x2 {
	return Mat3x2{m1[0] - m2[0], m1[1] - m2[1], m1[2] - m2[2], m1[3] - m2[3], m1[4] - m2[4], m1[5] - m2[5]}
}
645485
func (c *Websocket) Subprotocol() *String {
	s := &String{chain: c.chain}
	if c.conn != nil {
		s.value = c.conn.Subprotocol()
	}
	return s
}
1136925
func SliceSubsetOf(sub, main []string) (bool, []string) {
	var diff []string
	occurences := make(map[string]int, len(main))
	result := true
	for _, element := range main {
		occurences[element]++
	}
	for _, element := range sub {
		if count, ok := occurences[element]; !ok {
			// Element was not found in the main slice.
			result = false
			diff = append(diff, element)
		} else if count < 1 {
			// The element is in both slices, but the sub slice
			// has more duplicates.
			result = false
		} else {
			occurences[element]--
		}
	}
	return result, diff
}