textflag.go 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. // Copyright 2013 The Go Authors. All rights reserved.
  2. // Use of this source code is governed by a BSD-style
  3. // license that can be found in the LICENSE file.
  4. // This file defines flags attached to various functions
  5. // and data objects. The compilers, assemblers, and linker must
  6. // all agree on these values.
  7. package obj
  8. const (
  9. // Don't profile the marked routine.
  10. //
  11. // Deprecated: Not implemented, do not use.
  12. NOPROF = 1
  13. // It is ok for the linker to get multiple of these symbols. It will
  14. // pick one of the duplicates to use.
  15. DUPOK = 2
  16. // Don't insert stack check preamble.
  17. NOSPLIT = 4
  18. // Put this data in a read-only section.
  19. RODATA = 8
  20. // This data contains no pointers.
  21. NOPTR = 16
  22. // This is a wrapper function and should not count as disabling 'recover'.
  23. WRAPPER = 32
  24. // This function uses its incoming context register.
  25. NEEDCTXT = 64
  26. // When passed to ggloblsym, causes Local to be set to true on the LSym it creates.
  27. LOCAL = 128
  28. // Allocate a word of thread local storage and store the offset from the
  29. // thread local base to the thread local storage in this variable.
  30. TLSBSS = 256
  31. // Do not insert instructions to allocate a stack frame for this function.
  32. // Only valid on functions that declare a frame size of 0.
  33. // TODO(mwhudson): only implemented for ppc64x at present.
  34. NOFRAME = 512
  35. // Function can call reflect.Type.Method or reflect.Type.MethodByName.
  36. REFLECTMETHOD = 1024
  37. // Function is the top of the call stack. Call stack unwinders should stop
  38. // at this function.
  39. TOPFRAME = 2048
  40. )