www.digitalmars.com         C & C++   DMDScript  

D.gnu - [Bug 114] New: Add support for the GCC 'naked' attribute

Date: Wed, 2 Apr 2014 13:42:05 +0100
MIME-Version: 1.0
Content-Type: text/plain; charset="UTF-8"


            Bug ID: 114
           Summary: Add support for the GCC 'naked' attribute
    Classification: Unclassified
           Product: GDC
           Version: development
          Hardware: All
                OS: All
            Status: NEW
          Severity: enhancement
          Priority: Normal
         Component: gdc
          Assignee: ibuclaw gdcproject.org
          Reporter: slavo5150 yahoo.com

I'm targeting ARM Cortex-M bare metal, and I need my reset interrupt handler
marked with the 'naked' attribute as it will be called before I've initialized
my the hardware containing my stack.  

It can also be used to make a useful hard fault handler for finding elusive
bugs as described here. 

I could do what I need in assembly, but then I'd break my "do it all in D"

I propose the following syntax:

 attribute("naked") void myNakedFunction() { }

The GCC 'naked' attribute is documented here:

You are receiving this mail because:
You are watching all bug changes.
Apr 02 2014