Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 12 for RETPOLINE (0.14 sec)

  1. test/codegen/retpoline.go

    // asmcheck -gcflags=-spectre=ret
    
    //go:build amd64
    
    package codegen
    
    func CallFunc(f func()) {
    	// amd64:`CALL\truntime.retpoline`
    	f()
    }
    
    func CallInterface(x interface{ M() }) {
    	// amd64:`CALL\truntime.retpoline`
    	x.M()
    }
    
    // Check to make sure that jump tables are disabled
    // when retpoline is on. See issue 57097.
    func noJumpTables(x int) int {
    	switch x {
    	case 0:
    		return 0
    	case 1:
    		return 1
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Oct 19 23:33:25 UTC 2023
    - 580 bytes
    - Viewed (0)
  2. src/runtime/asm_amd64.s

    TEXT runtime·retpolineR8(SB),NOSPLIT|NOFRAME,$0; RETPOLINE(8)
    TEXT runtime·retpolineR9(SB),NOSPLIT|NOFRAME,$0; RETPOLINE(9)
    TEXT runtime·retpolineR10(SB),NOSPLIT|NOFRAME,$0; RETPOLINE(10)
    TEXT runtime·retpolineR11(SB),NOSPLIT|NOFRAME,$0; RETPOLINE(11)
    TEXT runtime·retpolineR12(SB),NOSPLIT|NOFRAME,$0; RETPOLINE(12)
    TEXT runtime·retpolineR13(SB),NOSPLIT|NOFRAME,$0; RETPOLINE(13)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Sat May 11 20:38:24 UTC 2024
    - 60.4K bytes
    - Viewed (0)
  3. src/cmd/asm/main.go

    		os.Exit(2)
    	case "":
    		// nothing
    	case "index":
    		// known to compiler; ignore here so people can use
    		// the same list with -gcflags=-spectre=LIST and -asmflags=-spectrre=LIST
    	case "all", "ret":
    		ctxt.Retpoline = true
    	}
    
    	ctxt.Bso = bufio.NewWriter(os.Stdout)
    	defer ctxt.Bso.Flush()
    
    	architecture.Init(ctxt)
    
    	// Create object file, write header.
    	buf, err := bio.Create(*flags.OutputFile)
    	if err != nil {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue May 14 19:41:17 UTC 2024
    - 2.9K bytes
    - Viewed (0)
  4. src/cmd/internal/obj/link.go

    	Flag_dynlink       bool
    	Flag_linkshared    bool
    	Flag_optimize      bool
    	Flag_locationlists bool
    	Flag_noRefName     bool   // do not include referenced symbol names in object file
    	Retpoline          bool   // emit use of retpoline stubs for indirect jmp/call
    	Flag_maymorestack  string // If not "", call this function before stack checks
    	Bso                *bufio.Writer
    	Pathname           string
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 15 19:57:43 UTC 2024
    - 33.1K bytes
    - Viewed (0)
  5. src/cmd/compile/internal/walk/switch.go

    	const minCases = 8   // have at least minCases cases in the switch
    	const minDensity = 4 // use at least 1 out of every minDensity entries
    
    	if base.Flag.N != 0 || !ssagen.Arch.LinkArch.CanJumpTable || base.Ctxt.Retpoline {
    		return false
    	}
    	if len(cc) < minCases {
    		return false // not enough cases for it to be worth it
    	}
    	if cc[0].lo.Val().Kind() != constant.Int {
    		return false // e.g. float
    	}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Mar 04 17:34:01 UTC 2024
    - 30.1K bytes
    - Viewed (0)
  6. src/cmd/internal/obj/mips/asm0.go

    }
    
    var oprange [ALAST & obj.AMask][]Optab
    
    var xcmp [C_NCLASS][C_NCLASS]bool
    
    func span0(ctxt *obj.Link, cursym *obj.LSym, newprog obj.ProgAlloc) {
    	if ctxt.Retpoline {
    		ctxt.Diag("-spectre=ret not supported on mips")
    		ctxt.Retpoline = false // don't keep printing
    	}
    
    	p := cursym.Func().Text
    	if p == nil || p.Link == nil { // handle external functions and ELF section symbols
    		return
    	}
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Apr 16 17:46:09 UTC 2024
    - 53.6K bytes
    - Viewed (0)
  7. src/cmd/internal/obj/loong64/asm.go

    }
    
    var oprange [ALAST & obj.AMask][]Optab
    
    var xcmp [C_NCLASS][C_NCLASS]bool
    
    func span0(ctxt *obj.Link, cursym *obj.LSym, newprog obj.ProgAlloc) {
    	if ctxt.Retpoline {
    		ctxt.Diag("-spectre=ret not supported on loong64")
    		ctxt.Retpoline = false // don't keep printing
    	}
    
    	p := cursym.Func().Text
    	if p == nil || p.Link == nil { // handle external functions and ELF section symbols
    		return
    	}
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 22 02:04:54 UTC 2024
    - 61.8K bytes
    - Viewed (0)
  8. src/cmd/internal/obj/x86/asm6.go

    			}
    		}
    		if ctxt.Retpoline && (p.As == obj.ACALL || p.As == obj.AJMP) && (p.To.Type == obj.TYPE_REG || p.To.Type == obj.TYPE_MEM) {
    			if p.To.Type != obj.TYPE_REG {
    				ctxt.Diag("non-retpoline-compatible: %v", p)
    				continue
    			}
    			p.To.Type = obj.TYPE_BRANCH
    			p.To.Name = obj.NAME_EXTERN
    			p.To.Sym = ctxt.Lookup("runtime.retpoline" + obj.Rconv(int(p.To.Reg)))
    			p.To.Reg = 0
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 15 15:44:14 UTC 2024
    - 146.9K bytes
    - Viewed (0)
  9. src/cmd/internal/obj/riscv/obj.go

    }
    
    // assemble emits machine code.
    // It is called at the very end of the assembly process.
    func assemble(ctxt *obj.Link, cursym *obj.LSym, newprog obj.ProgAlloc) {
    	if ctxt.Retpoline {
    		ctxt.Diag("-spectre=ret not supported on riscv")
    		ctxt.Retpoline = false // don't keep printing
    	}
    
    	// If errors were encountered during preprocess/validation, proceeding
    	// and attempting to encode said instructions will only lead to panics.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Sun Apr 07 03:32:27 UTC 2024
    - 77K bytes
    - Viewed (0)
  10. src/cmd/internal/obj/arm/asm5.go

    	if p.Scond&C_UBIT != 0 && o.scond&C_UBIT == 0 {
    		c.ctxt.Diag("invalid .U suffix: %v", p)
    	}
    }
    
    func span5(ctxt *obj.Link, cursym *obj.LSym, newprog obj.ProgAlloc) {
    	if ctxt.Retpoline {
    		ctxt.Diag("-spectre=ret not supported on arm")
    		ctxt.Retpoline = false // don't keep printing
    	}
    
    	var p *obj.Prog
    	var op *obj.Prog
    
    	p = cursym.Func().Text
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Dec 15 20:51:01 UTC 2023
    - 79.4K bytes
    - Viewed (0)
Back to top