Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 4 of 4 for nilcheckelim (0.2 sec)

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

    	opt(fun.f)
    	nilcheckelim(fun.f)
    
    	// clean up the removed nil check
    	fuse(fun.f, fuseTypePlain)
    	deadcode(fun.f)
    
    	CheckFunc(fun.f)
    	for _, b := range fun.f.Blocks {
    		if b == fun.blocks["secondCheck"] && isNilCheck(b) {
    			t.Errorf("secondCheck was not eliminated")
    		}
    	}
    }
    
    // TestNilcheckBug reproduces a bug in nilcheckelim found by compiling math/big
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Nov 17 23:34:11 UTC 2023
    - 12.3K bytes
    - Viewed (0)
  2. src/cmd/compile/internal/ssa/compile.go

    	{"generic cse", "dse"},
    	// cse substantially improves nilcheckelim efficacy
    	{"generic cse", "nilcheckelim"},
    	// allow deadcode to clean up after nilcheckelim
    	{"nilcheckelim", "generic deadcode"},
    	// nilcheckelim generates sequences of plain basic blocks
    	{"nilcheckelim", "late fuse"},
    	// nilcheckelim relies on opt to rewrite user nil checks
    	{"opt", "nilcheckelim"},
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Apr 22 14:55:18 UTC 2024
    - 18.6K bytes
    - Viewed (0)
  3. src/cmd/compile/internal/ssa/nilcheck.go

    // license that can be found in the LICENSE file.
    
    package ssa
    
    import (
    	"cmd/compile/internal/ir"
    	"cmd/internal/src"
    	"internal/buildcfg"
    )
    
    // nilcheckelim eliminates unnecessary nil checks.
    // runs on machine-independent code.
    func nilcheckelim(f *Func) {
    	// A nil check is redundant if the same nil check was successful in a
    	// dominating block. The efficacy of this pass depends heavily on the
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Oct 31 20:45:54 UTC 2023
    - 11.3K bytes
    - Viewed (0)
  4. src/cmd/compile/internal/ssa/schedule.go

    				continue
    			}
    			sset.add(v.MemoryArg().ID) // record that v's memory arg is used
    		}
    		if v.Op == OpNilCheck {
    			hasNilCheck = true
    		}
    	}
    	if len(stores) == 0 || !hasNilCheck && f.pass.name == "nilcheckelim" {
    		// there is no store, the order does not matter
    		return values
    	}
    
    	// find last store, which is the one that is not used by other stores
    	var last *Value
    	for _, v := range stores {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Apr 08 15:53:17 UTC 2024
    - 16.4K bytes
    - Viewed (0)
Back to top