Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
a6f1f7be
Commit
a6f1f7be
authored
Nov 01, 2022
by
Eric Pouech
Committed by
Alexandre Julliard
Nov 01, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dbghelp: No longer pass inline site's address upon creation.
Instead use the first address of the first defined range of address. Signed-off-by:
Eric Pouech
<
eric.pouech@gmail.com
>
parent
389df55d
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
10 additions
and
33 deletions
+10
-33
dbghelp_private.h
dlls/dbghelp/dbghelp_private.h
+0
-1
dwarf.c
dlls/dbghelp/dwarf.c
+3
-1
msc.c
dlls/dbghelp/msc.c
+5
-28
symbol.c
dlls/dbghelp/symbol.c
+2
-3
No files found.
dlls/dbghelp/dbghelp_private.h
View file @
a6f1f7be
...
...
@@ -850,7 +850,6 @@ extern struct symt_inlinesite*
struct
symt_function
*
func
,
struct
symt
*
parent
,
const
char
*
name
,
ULONG_PTR
addr
,
struct
symt
*
type
)
DECLSPEC_HIDDEN
;
extern
void
symt_add_func_line
(
struct
module
*
module
,
struct
symt_function
*
func
,
...
...
dlls/dbghelp/dwarf.c
View file @
a6f1f7be
...
...
@@ -2141,13 +2141,15 @@ static void dwarf2_parse_inlined_subroutine(dwarf2_subprogram_t* subpgm,
subpgm
->
top_func
,
subpgm
->
current_block
?
&
subpgm
->
current_block
->
symt
:
&
subpgm
->
current_func
->
symt
,
dwarf2_get_cpp_name
(
di
,
name
.
u
.
string
),
adranges
[
0
].
low
,
&
sig_type
->
symt
);
&
sig_type
->
symt
);
subpgm
->
current_func
=
(
struct
symt_function
*
)
inlined
;
subpgm
->
current_block
=
NULL
;
for
(
i
=
0
;
i
<
num_adranges
;
++
i
)
symt_add_inlinesite_range
(
subpgm
->
ctx
->
module_ctx
->
module
,
inlined
,
adranges
[
i
].
low
,
adranges
[
i
].
high
);
/* temporary: update address field */
inlined
->
func
.
address
=
adranges
[
0
].
low
;
free
(
adranges
);
children
=
dwarf2_get_di_children
(
di
);
...
...
dlls/dbghelp/msc.c
View file @
a6f1f7be
...
...
@@ -2101,7 +2101,7 @@ static struct symt_inlinesite* codeview_create_inline_site(const struct msc_debu
const
union
codeview_type
*
cvt
;
struct
symt_inlinesite
*
inlined
;
struct
cv_binannot
cvba
;
BOOL
srcok
,
found
=
FALSE
;
BOOL
srcok
;
unsigned
offset
,
line
,
srcfile
;
const
struct
CV_Checksum_t
*
chksms
;
...
...
@@ -2111,42 +2111,17 @@ static struct symt_inlinesite* codeview_create_inline_site(const struct msc_debu
return
NULL
;
}
/* grasp first code offset in binary annotation to compute inline site start address */
cvba
.
annot
=
annot
;
cvba
.
last_annot
=
last_annot
;
while
(
codeview_advance_binannot
(
&
cvba
))
if
(
cvba
.
opcode
==
BA_OP_CodeOffset
||
cvba
.
opcode
==
BA_OP_ChangeCodeOffset
||
cvba
.
opcode
==
BA_OP_ChangeCodeOffsetAndLineOffset
)
{
offset
=
cvba
.
arg1
;
found
=
TRUE
;
break
;
}
else
if
(
cvba
.
opcode
==
BA_OP_ChangeCodeLengthAndCodeOffset
)
{
offset
=
cvba
.
arg2
;
found
=
TRUE
;
break
;
}
if
(
!
found
)
{
WARN
(
"Couldn't find start address of inlined
\n
"
);
return
NULL
;
}
switch
(
cvt
->
generic
.
id
)
{
case
LF_FUNC_ID
:
inlined
=
symt_new_inlinesite
(
msc_dbg
->
module
,
top_func
,
container
,
cvt
->
func_id_v3
.
name
,
top_func
->
address
+
offset
,
cvt
->
func_id_v3
.
name
,
codeview_get_type
(
cvt
->
func_id_v3
.
type
,
FALSE
));
break
;
case
LF_MFUNC_ID
:
/* FIXME we just declare a function, not a method */
inlined
=
symt_new_inlinesite
(
msc_dbg
->
module
,
top_func
,
container
,
cvt
->
mfunc_id_v3
.
name
,
top_func
->
address
+
offset
,
cvt
->
mfunc_id_v3
.
name
,
codeview_get_type
(
cvt
->
mfunc_id_v3
.
type
,
FALSE
));
break
;
default:
...
...
@@ -2228,6 +2203,8 @@ static struct symt_inlinesite* codeview_create_inline_site(const struct msc_debu
if
(
range
->
low
==
range
->
high
)
WARN
(
"pending empty range at end of %s inside %s
\n
"
,
inlined
->
func
.
hash_elt
.
name
,
top_func
->
hash_elt
.
name
);
/* temporary: update address field */
inlined
->
func
.
address
=
((
struct
addr_range
*
)
vector_at
(
&
inlined
->
vranges
,
0
))
->
low
;
}
return
inlined
;
}
...
...
dlls/dbghelp/symbol.c
View file @
a6f1f7be
...
...
@@ -362,17 +362,16 @@ struct symt_inlinesite* symt_new_inlinesite(struct module* module,
struct
symt_function
*
func
,
struct
symt
*
container
,
const
char
*
name
,
ULONG_PTR
addr
,
struct
symt
*
sig_type
)
{
struct
symt_inlinesite
*
sym
;
TRACE_
(
dbghelp_symt
)(
"Adding inline site %s
@%Ix
\n
"
,
name
,
addr
);
TRACE_
(
dbghelp_symt
)(
"Adding inline site %s
\n
"
,
name
);
if
((
sym
=
pool_alloc
(
&
module
->
pool
,
sizeof
(
*
sym
))))
{
struct
symt
**
p
;
assert
(
container
);
init_function_or_inlinesite
(
&
sym
->
func
,
module
,
SymTagInlineSite
,
container
,
name
,
addr
,
0
,
sig_type
);
init_function_or_inlinesite
(
&
sym
->
func
,
module
,
SymTagInlineSite
,
container
,
name
,
0
,
0
,
sig_type
);
vector_init
(
&
sym
->
vranges
,
sizeof
(
struct
addr_range
),
2
);
/* FIXME: number of elts => to be set on input */
/* chain inline sites */
sym
->
func
.
next_inlinesite
=
func
->
next_inlinesite
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment