[Bug gprofng/29410] New: [display html] Argument " 0." isn't numeric in numeric gt (>)

2022-07-26 Thread ruud.vanderpas at oracle dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29410

Bug ID: 29410
   Summary: [display html] Argument " 0." isn't numeric in
numeric gt (>)
   Product: binutils
   Version: 2.39
Status: NEW
  Severity: normal
  Priority: P2
 Component: gprofng
  Assignee: ruud.vanderpas at oracle dot com
  Reporter: ruud.vanderpas at oracle dot com
  Target Milestone: ---

There a numerous warnings of the type "Argument " 0." isn't numeric in
numeric gt (>)". Clearly the operand used in the comparison is not numeric
indeed.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


[Bug gprofng/29410] [display html] Argument "  0." isn't numeric in numeric gt (>)

2022-07-26 Thread ruud.vanderpas at oracle dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29410

Ruud van der Pas  changed:

   What|Removed |Added

 CC||kurt.goebel at oracle dot com,
   ||vladimir.mezentsev at oracle 
dot c
   ||om

-- 
You are receiving this mail because:
You are on the CC list for the bug.


[Bug ld/29411] New: ld warning on SPARC: LOAD segment with RWX permissions

2022-07-26 Thread ro at gcc dot gnu.org
https://sourceware.org/bugzilla/show_bug.cgi?id=29411

Bug ID: 29411
   Summary: ld warning on SPARC: LOAD segment with RWX permissions
   Product: binutils
   Version: 2.39
Status: NEW
  Severity: normal
  Priority: P2
 Component: ld
  Assignee: unassigned at sourceware dot org
  Reporter: ro at gcc dot gnu.org
  Target Milestone: ---
  Host: sparcv9-sun-solaris2.11, sparc64-sun-linux-gnu
Target: sparcv9-sun-solaris2.11, sparc64-sun-linux-gnu
 Build: sparcv9-sun-solaris2.11, sparc64-sun-linux-gnu

When trying to build LLVM main on Debian/sparc64, I saw lots of warnings:

/usr/bin/ld: warning: bin/llvm-readobj has a LOAD segment with RWX permissions

/usr/bin/ld is

GNU ld (GNU Binutils for Debian) 2.38.50.20220707

However, the same issue exists on Solaris 11/SPARC.

AFAICS, this happens as follows (taking the Solaris example):

$ readelf -l /lib/libc.so.1
[...]
Program Headers:
  Type   Offset   VirtAddr   PhysAddr   FileSiz MemSiz  Flg Align
  PT_SUNWCAP 0xf4 0x00f4 0x 0x001a0 0x001a0 R   0x4
  LOAD   0x00 0x 0x 0x213913 0x213913 R E 0x1
  LOAD   0x214000 0x00224000 0x 0x0b9b8 0x11124 RWE 0x1
[...]
 Section to Segment mapping:
  Segment Sections...
   00 .SUNW_cap 
   01 .SUNW_cap .SUNW_capinfo .SUNW_capchain .dynamic .SUNW_syminfo .hash
.SUNW_ldynsym .dynsym .dynstr .SUNW_version .SUNW_versym .SUNW_dynsymsort
.SUNW_dyntlssort .SUNW_dynsymnsort .SUNW_phname .SUNW_reloc .rela.plt .rodata
.rodata1 .text .init .fini .SUNW_dof 
   02 .got .plt .data .picdata .bss 

Looking at the sections in segment 02, I find only one that is RWE:

$ readelf -S /lib/libc.so.1
[...]Section Headers:
  [Nr] Name  TypeAddr OffSize   ES Flg Lk Inf
Al
[...]
  [25] .plt  PROGBITS00224ca0 214ca0 0002a4 0c WAX  0   0 
4

However, this is exactly as prescribed by the respective psABIs:

* 32-bit SPARC:

  SYSTEM V APPLICATION BINARY INTERFACE SPARC Processor Supplement, Third
Edition
  p. 5-5 - 5-8, Procedure Linkage Table

* 64-bit SPARC V9:

  SPARC COMPLIANCE DEFINITION 2.4.1
  p. 5P-4 - 5P-8, Procedure Linkage Table

I have no idea what to do here, but warning about ABI-compliant binaries seems
strange.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


[Bug gprofng/29353] [display html] Fix a lay-out issue in the html disassembly files

2022-07-26 Thread kurt.goebel at oracle dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29353

Kurt Goebel  changed:

   What|Removed |Added

 Status|ASSIGNED|WAITING

-- 
You are receiving this mail because:
You are on the CC list for the bug.


[Bug gprofng/29352] [display html] Fix the message Hexadecimal number > 0xffffffff non-portable

2022-07-26 Thread kurt.goebel at oracle dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29352

Kurt Goebel  changed:

   What|Removed |Added

 Status|ASSIGNED|WAITING

-- 
You are receiving this mail because:
You are on the CC list for the bug.


[Bug gprofng/29356] [display html] Execution fails if gprofng is not included in PATH

2022-07-26 Thread kurt.goebel at oracle dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29356

Kurt Goebel  changed:

   What|Removed |Added

 Status|ASSIGNED|WAITING

-- 
You are receiving this mail because:
You are on the CC list for the bug.


[Bug gprofng/29351] [display html] Move dynamic loading of modules to a later stage

2022-07-26 Thread kurt.goebel at oracle dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29351

Kurt Goebel  changed:

   What|Removed |Added

 Status|ASSIGNED|WAITING

-- 
You are receiving this mail because:
You are on the CC list for the bug.


[Bug gprofng/29392] [display html] Unexpected line format in summary file

2022-07-26 Thread kurt.goebel at oracle dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29392

Kurt Goebel  changed:

   What|Removed |Added

 CC||kurt.goebel at oracle dot com
 Status|ASSIGNED|WAITING

-- 
You are receiving this mail because:
You are on the CC list for the bug.


[Bug ld/29393] Option to emit .debug_info CU version 4

2022-07-26 Thread nickc at redhat dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29393

Nick Clifton  changed:

   What|Removed |Added

 Resolution|--- |NOTABUG
 Status|UNCONFIRMED |RESOLVED
 CC||nickc at redhat dot com

--- Comment #1 from Nick Clifton  ---
(In reply to Jan Engelhardt from comment #0)

> I did not find an option to emit v4 CUs. gcc's -gdwarf-4 option has no
> effect in that regard, either.

The secret is that you need to use both gcc's dwarf-4 option and the
assembler's dwarf-4 option.  Like this:

  $ gcc x.c -g -gdwarf-4 -Wa,--gdwarf-4
  $ objdump -W a.out
  [...]
  Contents of the .debug_info section:

Compilation Unit @ offset 0x0:
 Length:0x4f (32-bit)
 Version:   4
 Abbrev Offset: 0x0
 Pointer Size:  8

You need the assembler's --gdwarf-4 option so that it will default to
generating a version 4 .debug_info section.  But you also need to use gcc's
-gdwarf-4 option as otherwise it will generated dwarf version 5 line table
information and the assembler will notice this and automatically bump the
version of dwarf that it generates to version 5.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


[Bug ld/29411] ld warning on SPARC: LOAD segment with RWX permissions

2022-07-26 Thread cvs-commit at gcc dot gnu.org
https://sourceware.org/bugzilla/show_bug.cgi?id=29411

--- Comment #1 from cvs-commit at gcc dot gnu.org  ---
The master branch has been updated by Nick Clifton :

https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=91896b4d6a7d312e850094eaaa5b965a9e3dc39b

commit 91896b4d6a7d312e850094eaaa5b965a9e3dc39b
Author: Nick Clifton 
Date:   Tue Jul 26 14:25:33 2022 +0100

Stop the linker from complaining about RWX segments in sparc-solaris
targets.

PR 29411
* configure.tgt (ac_default_ld_warn_rwx_segments): Disable for
sparc-solaris configurations.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


[Bug ld/29411] ld warning on SPARC: LOAD segment with RWX permissions

2022-07-26 Thread nickc at redhat dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29411

Nick Clifton  changed:

   What|Removed |Added

 Resolution|--- |FIXED
 CC||nickc at redhat dot com
 Status|NEW |RESOLVED

--- Comment #2 from Nick Clifton  ---
Hi Rainer,

  The warning is intended to alter users to the fact that a segment has been
created with all three permission flags set - something that is very tempting
to attackers looking to inject code into a binary.

  Disabling the warning for specific target configurations is possible however.
 There is a section of code at the start of ld/configure.tgt to do this.  

  I have gone ahead and added the sparc-solaris targets to the list of targets
for which the warning should be supressed by default.  (It can still be enabled
via a command line option, if the user so desires).

Cheers
  Nick

-- 
You are receiving this mail because:
You are on the CC list for the bug.


[Bug ld/29411] ld warning on SPARC: LOAD segment with RWX permissions

2022-07-26 Thread ro at CeBiTec dot Uni-Bielefeld.DE
https://sourceware.org/bugzilla/show_bug.cgi?id=29411

--- Comment #4 from Rainer Orth  ---
> --- Comment #2 from Nick Clifton  ---
> Hi Rainer,
>
>   The warning is intended to alter users to the fact that a segment has been
> created with all three permission flags set - something that is very tempting
> to attackers looking to inject code into a binary.
>
>   Disabling the warning for specific target configurations is possible 
> however.
>  There is a section of code at the start of ld/configure.tgt to do this.  
>
>   I have gone ahead and added the sparc-solaris targets to the list of targets
> for which the warning should be supressed by default.  (It can still be 
> enabled
> via a command line option, if the user so desires).

I missed this, although I saw the initial discussion about this warning
fly by.  However, this is not a Solaris/SPARC-only issue: I first saw it
on Linux/sparc64.  Given the SPARC and SPARC V9 psABIs, I guess it
affects at least all SPARC/ELF targets (if not SPARC in general).

Thanks.
Rainer

-- 
You are receiving this mail because:
You are on the CC list for the bug.


[Bug ld/29411] ld warning on SPARC: LOAD segment with RWX permissions

2022-07-26 Thread cvs-commit at gcc dot gnu.org
https://sourceware.org/bugzilla/show_bug.cgi?id=29411

--- Comment #3 from cvs-commit at gcc dot gnu.org  ---
The binutils-2_39-branch branch has been updated by Nick Clifton
:

https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=41b6fc466ce51f094c53b60f767cd000c41d4c2d

commit 41b6fc466ce51f094c53b60f767cd000c41d4c2d
Author: Nick Clifton 
Date:   Tue Jul 26 14:31:13 2022 +0100

Stop the linker from complaining about RWX segments on sparc-solaris
targets.

PR 29411
* configure.tgt (ac_default_ld_warn_rwx_segments): Disable for
sparc-solaris configurations.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


Re: Binutils bug compiling Gnome Text Editor on Windows

2022-07-26 Thread Nick Clifton

Hi Zachary,

I'm unable to register on Bugzilla so I can't file this there. However, while trying to compile the Gnome Text Editor on Windows using msys2 I found the following error 
which caused compilation to cease. It's quite long so I pasted it here https://pastebin.mozilla.org/kbwhHzh7 


Unfortunately that gives me a "404 snippet not found error".

Some things that you might like to consider/try:

  * Are you running out of memory ?
(I am not familiar with the Gnome Text Editor, but Gnome programs
in general tend to be quite big).

  * Are you using the latest version of the binutils ?
(This is version 2.38 at the time of writing).

  * Is the error specific to the msys2 environment ?
(Maybe building under Cygwin or Linux might work).

Cheers
  Nick





[Bug gprofng/29368] The installation process should check for the makeinfo version

2022-07-26 Thread kurt.goebel at oracle dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29368

Kurt Goebel  changed:

   What|Removed |Added

 Status|ASSIGNED|WAITING

-- 
You are receiving this mail because:
You are on the CC list for the bug.


[Bug ld/29411] ld warning on SPARC: LOAD segment with RWX permissions

2022-07-26 Thread nickc at redhat dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=29411

Nick Clifton  changed:

   What|Removed |Added

 Resolution|FIXED   |---
 Status|RESOLVED|REOPENED

--- Comment #5 from Nick Clifton  ---
(In reply to Rainer Orth from comment #4)

> I missed this, although I saw the initial discussion about this warning
> fly by.  However, this is not a Solaris/SPARC-only issue: I first saw it
> on Linux/sparc64.  Given the SPARC and SPARC V9 psABIs, I guess it
> affects at least all SPARC/ELF targets (if not SPARC in general).

Ah - I missed this.  Would you mind applying a small patch on top of mine then,
that tweaks the regexp for sparc targets ?  (I am just a little bit swamped at
the moment.  I have come back from PTO to find 19,756 emails waiting for me...)

-- 
You are receiving this mail because:
You are on the CC list for the bug.


[Bug ld/29411] ld warning on SPARC: LOAD segment with RWX permissions

2022-07-26 Thread ro at CeBiTec dot Uni-Bielefeld.DE
https://sourceware.org/bugzilla/show_bug.cgi?id=29411

--- Comment #6 from Rainer Orth  ---
> --- Comment #5 from Nick Clifton  ---
> (In reply to Rainer Orth from comment #4)
>
>> I missed this, although I saw the initial discussion about this warning
>> fly by.  However, this is not a Solaris/SPARC-only issue: I first saw it
>> on Linux/sparc64.  Given the SPARC and SPARC V9 psABIs, I guess it
>> affects at least all SPARC/ELF targets (if not SPARC in general).
>
> Ah - I missed this.  Would you mind applying a small patch on top of mine 
> then,
> that tweaks the regexp for sparc targets ?  (I am just a little bit swamped at
> the moment.  I have come back from PTO to find 19,756 emails waiting for 
> me...)

Sure.  I'll check if we want this for all SPARC targets or restrict to
some subset (ELF) somehow.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


[Bug gprofng/29368] The installation process should check for the makeinfo version

2022-07-26 Thread cvs-commit at gcc dot gnu.org
https://sourceware.org/bugzilla/show_bug.cgi?id=29368

--- Comment #1 from cvs-commit at gcc dot gnu.org  ---
The master branch has been updated by Vladimir Mezentsev
:

https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=9c6dd6885bd765ba244aff77ac80c3e582ee551d

commit 9c6dd6885bd765ba244aff77ac80c3e582ee551d
Author: Vladimir Mezentsev 
Date:   Mon Jul 25 23:57:46 2022 -0700

gprofng: check for the makeinfo version

gprofng/ChangeLog
2022-07-25  Vladimir Mezentsev  

PR gprofng/29368
* configure.ac: Check for the makeinfo version.
* configure: Rebuild.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


[Bug gprofng/29368] The installation process should check for the makeinfo version

2022-07-26 Thread cvs-commit at gcc dot gnu.org
https://sourceware.org/bugzilla/show_bug.cgi?id=29368

--- Comment #2 from cvs-commit at gcc dot gnu.org  ---
The binutils-2_39-branch branch has been updated by Vladimir Mezentsev
:

https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=fc9672939576752123aebfa3e6f4d4f1b9674dd2

commit fc9672939576752123aebfa3e6f4d4f1b9674dd2
Author: Vladimir Mezentsev 
Date:   Mon Jul 25 23:57:46 2022 -0700

gprofng: check for the makeinfo version

gprofng/ChangeLog
2022-07-25  Vladimir Mezentsev  

PR gprofng/29368
* configure.ac: Check for the makeinfo version.
* configure: Rebuild.

-- 
You are receiving this mail because:
You are on the CC list for the bug.