Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 21 for SparseMap (0.49 sec)

  1. src/cmd/compile/internal/ssa/sparsemap.go

    	key ID
    	val int32
    }
    
    type sparseMap struct {
    	dense  []sparseEntry
    	sparse []int32
    }
    
    // newSparseMap returns a sparseMap that can map
    // integers between 0 and n-1 to int32s.
    func newSparseMap(n int) *sparseMap {
    	return &sparseMap{dense: nil, sparse: make([]int32, n)}
    }
    
    func (s *sparseMap) cap() int {
    	return len(s.sparse)
    }
    
    func (s *sparseMap) size() int {
    	return len(s.dense)
    }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Oct 31 21:41:06 UTC 2022
    - 1.9K bytes
    - Viewed (0)
  2. src/cmd/compile/internal/ssa/allocators.go

    func (c *Cache) allocSparseMap(n int) *sparseMap {
    	var s *sparseMap
    	n2 := n
    	if n2 < 32 {
    		n2 = 32
    	}
    	b := bits.Len(uint(n2 - 1))
    	v := poolFreeSparseMap[b-5].Get()
    	if v == nil {
    		s = newSparseMap(1 << b)
    	} else {
    		s = v.(*sparseMap)
    	}
    	return s
    }
    func (c *Cache) freeSparseMap(s *sparseMap) {
    	s.clear()
    	b := bits.Len(uint(s.cap()) - 1)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Feb 15 23:00:54 UTC 2023
    - 7.4K bytes
    - Viewed (0)
  3. src/archive/tar/reader.go

    		return nil, ErrHeader
    	}
    
    	// There should be two numbers in sparseMap for each entry.
    	sparseMap := strings.Split(paxHdrs[paxGNUSparseMap], ",")
    	if len(sparseMap) == 1 && sparseMap[0] == "" {
    		sparseMap = sparseMap[:0]
    	}
    	if int64(len(sparseMap)) != 2*numEntries {
    		return nil, ErrHeader
    	}
    
    	// Loop through the entries in the sparse map.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Mar 08 01:59:14 UTC 2024
    - 26.8K bytes
    - Viewed (0)
  4. src/cmd/compile/internal/ssa/biasedsparsemap.go

    package ssa
    
    import (
    	"math"
    )
    
    // A biasedSparseMap is a sparseMap for integers between J and K inclusive,
    // where J might be somewhat larger than zero (and K-J is probably much smaller than J).
    // (The motivating use case is the line numbers of statements for a single function.)
    // Not all features of a SparseMap are exported, and it is also easy to treat a
    // biasedSparseMap like a SparseSet.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Oct 31 21:41:06 UTC 2022
    - 2.7K bytes
    - Viewed (0)
  5. src/cmd/compile/internal/ssa/_gen/allocators.go

    			capacity: "%s.cap()",
    			mak:      "newSparseSet(%s)",
    			resize:   "", // larger-sized sparse sets are ok
    			clear:    "%s.clear()",
    			minLog:   5,
    			maxLog:   32,
    		},
    		{
    			name:     "SparseMap",
    			typ:      "*sparseMap",
    			capacity: "%s.cap()",
    			mak:      "newSparseMap(%s)",
    			resize:   "", // larger-sized sparse maps are ok
    			clear:    "%s.clear()",
    			minLog:   5,
    			maxLog:   32,
    		},
    		{
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Nov 17 23:34:11 UTC 2023
    - 6.7K bytes
    - Viewed (0)
  6. src/cmd/compile/internal/ssa/deadstore.go

    // A shadowRange encodes a set of byte offsets [lo():hi()] from
    // a given pointer that will be written to later in the block.
    // A zero shadowRange encodes an empty shadowed range (and so
    // does a -1 shadowRange, which is what sparsemap.get returns
    // on a failed lookup).
    type shadowRange int32
    
    func (sr shadowRange) lo() int64 {
    	return int64(sr & 0xffff)
    }
    
    func (sr shadowRange) hi() int64 {
    	return int64((sr >> 16) & 0xffff)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Apr 25 20:07:26 UTC 2024
    - 11K bytes
    - Viewed (0)
  7. src/cmd/compile/internal/ssa/func.go

    }
    
    // newSparseMap returns a sparse map that can store at least up to n integers.
    func (f *Func) newSparseMap(n int) *sparseMap {
    	return f.Cache.allocSparseMap(n)
    }
    
    // retSparseMap returns a sparse map to the config's cache of sparse
    // sets to be reused by f.newSparseMap.
    func (f *Func) retSparseMap(ss *sparseMap) {
    	f.Cache.freeSparseMap(ss)
    }
    
    // newSparseMapPos returns a sparse map that can store at least up to n integers.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Jun 10 19:44:43 UTC 2024
    - 25.8K bytes
    - Viewed (0)
  8. subprojects/core/src/main/java/org/gradle/internal/typeconversion/MapNotationConverter.java

                for (Method method : clazz.getDeclaredMethods()) {
                    if (method.getName().equals("parseMap")) {
                        method.setAccessible(true);
                        return method;
                    }
                }
                throw new UnsupportedOperationException(String.format("No parseMap() method found on class %s.", clazz.getSimpleName()));
            }
    
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Mon Apr 12 07:52:07 UTC 2021
    - 6.9K bytes
    - Viewed (0)
  9. platforms/software/dependency-management/src/main/java/org/gradle/api/internal/notations/DependencyMapNotationConverter.java

        }
    
        @Override
        public void describe(DiagnosticsVisitor visitor) {
            visitor.candidate("Maps").example("[group: 'org.gradle', name: 'gradle-core', version: '1.0']");
        }
    
        protected T parseMap(@MapKey("group") @Nullable String group,
                             @MapKey("name") @Nullable String name,
                             @MapKey("version") @Nullable String version,
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Tue Oct 10 21:10:11 UTC 2023
    - 2.4K bytes
    - Viewed (0)
  10. platforms/software/dependency-management/src/main/java/org/gradle/api/internal/artifacts/dsl/CapabilityNotationParserFactory.java

            public void describe(DiagnosticsVisitor visitor) {
                visitor.candidate("Maps").example("[group: 'org.group', name: 'capability', version: '1.0']");
            }
    
            protected Capability parseMap(@MapKey("group") String group,
                                          @MapKey("name") String name,
                                          @MapKey("version") String version) {
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Tue Oct 10 21:10:11 UTC 2023
    - 5.4K bytes
    - Viewed (0)
Back to top