Bug 914630 - GNAT computes size of the object to be allocated incorrectly
Summary: GNAT computes size of the object to be allocated incorrectly
Keywords:
Status: CLOSED UPSTREAM
Alias: None
Product: Fedora
Classification: Fedora
Component: gcc
Version: 19
Hardware: All
OS: Linux
unspecified
high
Target Milestone: ---
Assignee: Jakub Jelinek
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: 913852
TreeView+ depends on / blocked
 
Reported: 2013-02-22 10:54 UTC by Pavel Zhukov
Modified: 2014-06-18 07:21 UTC (History)
6 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-05-14 17:21:47 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
GNU Compiler Collection 56474 0 None None None Never

Description Pavel Zhukov 2013-02-22 10:54:32 UTC
Description of problem:
GNAT computes size of the object to be allocated incorrectly

Version-Release number of selected component (if applicable):
gcc-4.8 from the rawhide tree

How reproducible:
100%

Steps to Reproduce:
1.rebuild matreshka package
  
Actual results:
failed to build please see bug 913852 and rawhide report.

Additional info:

Comment 1 Pavel Zhukov 2013-02-22 23:40:38 UTC
Smaller reproducer:

with Ada.Streams;

package Pkg is
   use type Ada.Streams.Stream_Element_Offset;

   type Vector (Size : Ada.Streams.Stream_Element_Offset) is record
      Value : Ada.Streams.Stream_Element_Array (0 .. Size);
   end record;

   Empty_Vector : Vector (-1);
   
end Pkg;

with Pkg;
procedure Bbb is
begin
   null;
end Bbb;

$ gnatmake bbb
gcc -c bbb.adb
gcc -c pkg.ads
pkg.ads:10:04: warning: "Storage_Error" will be raised at run time
gnatbind -x bbb.ali
gnatlink bbb.ali

$ ./bbb

raised STORAGE_ERROR : object too large

Comment 2 Fedora End Of Life 2013-04-03 15:07:08 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 19 development cycle.
Changing version to '19'.

(As we did not run this process for some time, it could affect also pre-Fedora 19 development
cycle bugs. We are very sorry. It will help us with cleanup during Fedora 19 End Of Life. Thank you.)

More information and reason for this action is here:
https://fedoraproject.org/wiki/BugZappers/HouseKeeping/Fedora19


Note You need to log in before you can comment on or make changes to this bug.