Re: BPF relocations

2017-05-20 Thread Maciej W. Rozycki
On Fri, 12 May 2017, David Miller wrote: > Internally, we have to emit some kind of relocation as GAS makes it's > first pass over the instructions. Not really, you can defer that until the relaxation pass, e.g. to avoid figuring out what to do about forward local symbol references, especially

Re: BPF relocations

2017-05-11 Thread Alexei Starovoitov
On 5/11/17 6:19 PM, David Miller wrote: From: Alexei Starovoitov Date: Thu, 11 May 2017 16:10:35 -0700 I don't see what we would use pc-relative relo for. We must have them at least for banches. Internally, we have to emit some kind of relocation as GAS makes it's first pass over the instru

Re: BPF relocations

2017-05-11 Thread David Miller
From: Alexei Starovoitov Date: Thu, 11 May 2017 16:10:35 -0700 > I don't see what we would use pc-relative relo for. We must have them at least for banches. Internally, we have to emit some kind of relocation as GAS makes it's first pass over the instructions. Afterwards, it walks the relocati

Re: BPF relocations

2017-05-11 Thread Alexei Starovoitov
On 5/11/17 12:31 PM, David Miller wrote: I haven't done more work on bintuils BPF support because we need to figure out exactly what to do with relocations. So I've been trying to spend time thinking about this. As far as I can tell the 64-bit BPF relocation llvm uses is used in two situations