[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Octave-bug-tracker] [bug #61821] segfault using tree_parameter_list in
From: |
anonymous |
Subject: |
[Octave-bug-tracker] [bug #61821] segfault using tree_parameter_list in oct file |
Date: |
Tue, 22 Feb 2022 16:32:49 -0500 (EST) |
Follow-up Comment #12, bug #61821 (project octave):
Thanks! I downloaded the artifact and extracted it into the official installed
alpha version. Some of dependencies are different between the official and the
artifact so I placed the required libraries and I now can run octave but the
test case results in segfault.
I decided to compile ov-usr-fcn.cc manually. I used the command shell of the
official alpha version. The only used compiler options was -O2.
Two errors were generated:
-line 647 "Fwarning" should be replaced by "octave::Fwarning"
-line 885 "set_internal_variable" should be replaced by
"octave::set_internal_variable"
After correcting the errors and compiling I inspected the disassembly of
"octave_user_function::define_ret_list".
00001570
<__ZN20octave_user_function15define_ret_listEPN6octave19tree_parameter_listE>:
1570: 8b 54 24 04 mov 0x4(%esp),%edx
1574: 89 c8 mov %ecx,%eax
1576: 89 91 c0 00 00 00 mov %edx,0xc0(%ecx)
157c: c2 04 00 ret $0x4
157f: 90 nop
It shows that the code is correctly generated and 0xc0 is generated instead of
0xd4.
Using the same shell I used ./configure and make to build Octave. Wonderfully
no compiler error was generated when building "ov-usr-fcn.cc". The disassembly
of "liboctave_value_la-ov-usr-fcn.o" shows that the code is wrongly
generated:
00001590
<__ZN20octave_user_function15define_ret_listEPN6octave19tree_parameter_listE>:
1590: 8b 54 24 04 mov 0x4(%esp),%edx
1594: 89 c8 mov %ecx,%eax
1596: 89 91 d4 00 00 00 mov %edx,0xd4(%ecx)
159c: c2 04 00 ret $0x4
159f: 90 nop
I broke the make process and corrected "ov-usr-fcn.cc" and executed make again
but the generated code still is wrong.
So it may be a configure/compiler option that forces gcc to generate wrong
code?!
_______________________________________________________
Reply to this item at:
<https://savannah.gnu.org/bugs/?61821>
_______________________________________________
Message sent via Savannah
https://savannah.gnu.org/
- [Octave-bug-tracker] [bug #61821] segfault using tree_parameter_list in oct file, Markus Mützel, 2022/02/22
- [Octave-bug-tracker] [bug #61821] segfault using tree_parameter_list in oct file,
anonymous <=
- [Octave-bug-tracker] [bug #61821] segfault using tree_parameter_list in oct file, Markus Mützel, 2022/02/23
- [Octave-bug-tracker] [bug #61821] segfault using tree_parameter_list in oct file, anonymous, 2022/02/23
- [Octave-bug-tracker] [bug #61821] segfault using tree_parameter_list in oct file, anonymous, 2022/02/23
- [Octave-bug-tracker] [bug #61821] segfault using tree_parameter_list in oct file, anonymous, 2022/02/24
- [Octave-bug-tracker] [bug #61821] segfault using tree_parameter_list in oct file, John W. Eaton, 2022/02/24
- [Octave-bug-tracker] [bug #61821] segfault using tree_parameter_list in oct file, Markus Mützel, 2022/02/24
- [Octave-bug-tracker] [bug #61821] segfault using tree_parameter_list in oct file, anonymous, 2022/02/24
- [Octave-bug-tracker] [bug #61821] segfault using tree_parameter_list in oct file, Markus Mützel, 2022/02/26
- [Octave-bug-tracker] [bug #61821] segfault using tree_parameter_list in oct file, Markus Mützel, 2022/02/26
- [Octave-bug-tracker] [bug #61821] segfault using tree_parameter_list in oct file, Markus Mützel, 2022/02/27