Home | History | Annotate | Download | only in obj

Lines Matching refs:ctxt

72 func (s *LSym) prepwrite(ctxt *Link, off int64, siz int) {
74 ctxt.Diag("prepwrite: bad off=%d siz=%d s=%v", off, siz, s)
82 ctxt.Diag("cannot supply data for %v var %v", s.Type, s.Name)
92 func (s *LSym) WriteFloat32(ctxt *Link, off int64, f float32) {
93 s.prepwrite(ctxt, off, 4)
94 ctxt.Arch.ByteOrder.PutUint32(s.P[off:], math.Float32bits(f))
98 func (s *LSym) WriteFloat64(ctxt *Link, off int64, f float64) {
99 s.prepwrite(ctxt, off, 8)
100 ctxt.Arch.ByteOrder.PutUint64(s.P[off:], math.Float64bits(f))
104 func (s *LSym) WriteInt(ctxt *Link, off int64, siz int, i int64) {
105 s.prepwrite(ctxt, off, siz)
108 ctxt.Diag("WriteInt: bad integer size: %d", siz)
112 ctxt.Arch.ByteOrder.PutUint16(s.P[off:], uint16(i))
114 ctxt.Arch.ByteOrder.PutUint32(s.P[off:], uint32(i))
116 ctxt.Arch.ByteOrder.PutUint64(s.P[off:], uint64(i))
120 func (s *LSym) writeAddr(ctxt *Link, off int64, siz int, rsym *LSym, roff int64, rtype objabi.RelocType) {
122 if siz != ctxt.Arch.PtrSize && siz != 4 {
123 ctxt.Diag("WriteAddr: bad address size %d in %s", siz, s.Name)
125 s.prepwrite(ctxt, off, siz)
129 ctxt.Diag("WriteAddr: off overflow %d in %s", off, s.Name)
139 func (s *LSym) WriteAddr(ctxt *Link, off int64, siz int, rsym *LSym, roff int64) {
140 s.writeAddr(ctxt, off, siz, rsym, roff, objabi.R_ADDR)
147 func (s *LSym) WriteCURelativeAddr(ctxt *Link, off int64, rsym *LSym, roff int64) {
148 s.writeAddr(ctxt, off, ctxt.Arch.PtrSize, rsym, roff, objabi.R_ADDRCUOFF)
154 func (s *LSym) WriteOff(ctxt *Link, off int64, rsym *LSym, roff int64) {
155 s.prepwrite(ctxt, off, 4)
159 ctxt.Diag("WriteOff: off overflow %d in %s", off, s.Name)
170 func (s *LSym) WriteWeakOff(ctxt *Link, off int64, rsym *LSym, roff int64) {
171 s.prepwrite(ctxt, off, 4)
175 ctxt.Diag("WriteOff: off overflow %d in %s", off, s.Name)
184 func (s *LSym) WriteString(ctxt *Link, off int64, siz int, str string) {
186 ctxt.Diag("WriteString: bad string size: %d < %d", siz, len(str))
188 s.prepwrite(ctxt, off, siz)
193 func (s *LSym) WriteBytes(ctxt *Link, off int64, b []byte) int64 {
194 s.prepwrite(ctxt, off, len(b))