File tree Expand file tree Collapse file tree 8 files changed +4
-17
lines changed Expand file tree Collapse file tree 8 files changed +4
-17
lines changed Original file line number Diff line number Diff line change @@ -216,7 +216,6 @@ impl ObjArch for ObjArchArm {
216
216
mnemonic : Cow :: Borrowed ( parsed_ins. mnemonic ) ,
217
217
args,
218
218
reloc,
219
- fake_pool_reloc : None ,
220
219
branch_dest,
221
220
line,
222
221
formatted : parsed_ins. display ( display_options) . to_string ( ) ,
Original file line number Diff line number Diff line change @@ -59,7 +59,6 @@ impl ObjArch for ObjArchArm64 {
59
59
mnemonic : Cow :: Borrowed ( "<invalid>" ) ,
60
60
args : vec ! [ ] ,
61
61
reloc : None ,
62
- fake_pool_reloc : None ,
63
62
branch_dest : None ,
64
63
line : None ,
65
64
formatted : "" . to_string ( ) ,
@@ -122,7 +121,6 @@ impl ObjArch for ObjArchArm64 {
122
121
mnemonic : Cow :: Borrowed ( mnemonic) ,
123
122
args,
124
123
reloc,
125
- fake_pool_reloc : None ,
126
124
branch_dest,
127
125
line,
128
126
formatted : ins. to_string ( ) ,
Original file line number Diff line number Diff line change @@ -205,7 +205,6 @@ impl ObjArch for ObjArchMips {
205
205
mnemonic : Cow :: Borrowed ( mnemonic) ,
206
206
args,
207
207
reloc : reloc. cloned ( ) ,
208
- fake_pool_reloc : None ,
209
208
branch_dest,
210
209
line,
211
210
formatted,
Original file line number Diff line number Diff line change @@ -150,8 +150,7 @@ impl ObjArch for ObjArchPpc {
150
150
size : 4 ,
151
151
mnemonic : Cow :: Borrowed ( simplified. mnemonic ) ,
152
152
args,
153
- reloc : reloc. cloned ( ) ,
154
- fake_pool_reloc : fake_pool_reloc_for_addr. get ( & cur_addr) . cloned ( ) ,
153
+ reloc : reloc. or ( fake_pool_reloc_for_addr. get ( & cur_addr) ) . cloned ( ) ,
155
154
op : ins. op as u16 ,
156
155
branch_dest,
157
156
line,
@@ -195,12 +194,7 @@ impl ObjArch for ObjArchPpc {
195
194
}
196
195
197
196
fn guess_data_type ( & self , instruction : & ObjIns ) -> Option < super :: DataType > {
198
- if instruction
199
- . reloc
200
- . as_ref ( )
201
- . or ( instruction. fake_pool_reloc . as_ref ( ) )
202
- . is_some_and ( |r| r. target . name . starts_with ( "@stringBase" ) )
203
- {
197
+ if instruction. reloc . as_ref ( ) . is_some_and ( |r| r. target . name . starts_with ( "@stringBase" ) ) {
204
198
return Some ( DataType :: String ) ;
205
199
}
206
200
Original file line number Diff line number Diff line change @@ -54,7 +54,6 @@ impl ObjArch for ObjArchX86 {
54
54
mnemonic : Cow :: Borrowed ( "<invalid>" ) ,
55
55
args : vec ! [ ] ,
56
56
reloc : None ,
57
- fake_pool_reloc : None ,
58
57
branch_dest : None ,
59
58
line : None ,
60
59
formatted : String :: new ( ) ,
@@ -80,7 +79,6 @@ impl ObjArch for ObjArchX86 {
80
79
mnemonic : Cow :: Borrowed ( "<invalid>" ) ,
81
80
args : vec ! [ ] ,
82
81
reloc : reloc. cloned ( ) ,
83
- fake_pool_reloc : None ,
84
82
branch_dest : None ,
85
83
line,
86
84
formatted : String :: new ( ) ,
Original file line number Diff line number Diff line change @@ -31,7 +31,7 @@ pub fn process_code_symbol(
31
31
) ?;
32
32
33
33
for inst in res. insts . iter_mut ( ) {
34
- if let Some ( reloc) = & mut inst. fake_pool_reloc {
34
+ if let Some ( reloc) = & mut inst. reloc {
35
35
if reloc. target . size == 0 && reloc. target . name . is_empty ( ) {
36
36
// Fake target symbol we added as a placeholder. We need to find the real one.
37
37
if let Some ( real_target) =
Original file line number Diff line number Diff line change @@ -106,7 +106,6 @@ pub struct ObjIns {
106
106
pub mnemonic : Cow < ' static , str > ,
107
107
pub args : Vec < ObjInsArg > ,
108
108
pub reloc : Option < ObjReloc > ,
109
- pub fake_pool_reloc : Option < ObjReloc > ,
110
109
pub branch_dest : Option < u64 > ,
111
110
/// Line number
112
111
pub line : Option < u32 > ,
Original file line number Diff line number Diff line change @@ -118,7 +118,7 @@ fn ins_hover_ui(
118
118
}
119
119
}
120
120
121
- if let Some ( reloc) = ins. reloc . as_ref ( ) . or ( ins . fake_pool_reloc . as_ref ( ) ) {
121
+ if let Some ( reloc) = & ins. reloc {
122
122
ui. label ( format ! ( "Relocation type: {}" , obj. arch. display_reloc( reloc. flags) ) ) ;
123
123
let addend_str = match reloc. addend . cmp ( & 0i64 ) {
124
124
Ordering :: Greater => format ! ( "+{:x}" , reloc. addend) ,
You can’t perform that action at this time.
0 commit comments