1    /* 
     2     *  Copyright (c) 2008 Texas Instruments and others.
     3     *  All rights reserved. This program and the accompanying materials
     4     *  are made available under the terms of the Eclipse Public License v1.0
     5     *  which accompanies this distribution, and is available at
     6     *  http://www.eclipse.org/legal/epl-v10.html
     7     * 
     8     *  Contributors:
     9     *      Texas Instruments - initial implementation
    10     * 
    11     * */
    12    
    13    /*
    14     *  ======== C55_huge.xdc ========
    15     *
    16     */
    17    
    18    /*!
    19     *  ======== C55_huge ========
    20     *  TI C55 big endian huge data model
    21     */
    22    metaonly module C55_huge inherits ti.targets.ITarget {
    23        override readonly config string name                = "C55_huge";   
    24        override readonly config string suffix              = "55H";
    25        override readonly config string isa                 = "55"; 
    26        override readonly config xdc.bld.ITarget.Model model= {
    27            endian: "big",
    28            dataModel: "huge"
    29        };
    30        override readonly config string rts                 = "ti.targets.rts5500";
    31    
    32        override readonly config xdc.bld.ITarget.Module base= ti.targets.C55;
    33    
    34        override readonly config xdc.bld.ITarget2.Command ar = {
    35            cmd: "ar55",
    36            opts: "rq"
    37        };
    38    
    39        /*!
    40         *  ======== cc ========
    41         *  Required options:
    42         *  @p(dlist)
    43         *      -`--memory_model=huge`
    44         *          huge model; data pointers are greater than 16-bits
    45         *      -`-vcore:3`
    46         *          huge model is only supported on rev 3 cores (and above)
    47         */
    48        override readonly config xdc.bld.ITarget2.Command cc = {
    49            cmd: "cl55 -c",
    50            opts: "--memory_model=huge -vcore:3"
    51        };
    52    
    53        override readonly config xdc.bld.ITarget2.Command vers = {
    54            cmd: "cl55",
    55            opts: ""
    56        };
    57    
    58        /*!
    59         *  ======== asm ========
    60         *  Required options:
    61         *  @p(dlist)
    62         *      -`--memory_model=huge`
    63         *          huge model; data pointers are greater than 16-bits
    64         *      -`-vcore:3`
    65         *          huge model is only supported on rev 3 cores (and above)
    66         */
    67        override readonly config xdc.bld.ITarget2.Command asm = {
    68            cmd: "cl55 -c",
    69            opts: "--memory_model=huge -vcore:3"
    70        };
    71    
    72        override readonly config xdc.bld.ITarget2.Command lnk = {
    73            cmd: "lnk55",
    74            opts: ""
    75        };
    76    
    77        /*!
    78         *  ======== asmOpts ========
    79         *  User configurable assembler options.
    80         *
    81         *  Defaults:
    82         *  @p(dlist)
    83         *      -`-qq`
    84         *          super quiet mode
    85         */
    86        override config xdc.bld.ITarget2.Options asmOpts = {
    87            prefix: "-qq",
    88            suffix: ""
    89        };
    90    
    91        /*!
    92         *  ======== ccOpts ========
    93         *  User configurable compiler options.
    94         *
    95         *  Defaults:
    96         *  @p(dlist)
    97         *      -`-qq`
    98         *          super quiet mode
    99         *      -`-pdsw225`
   100         *          generate a warning for implicitly declared functions; i.e.,
   101         *          functions without prototypes
   102         *      -`-Dfar=`
   103         *          ignore keyword far; this allows one to write code that can
   104         *          be compiled in large model and small model without #ifdef's
   105         */
   106        override config xdc.bld.ITarget2.Options ccOpts = {
   107            prefix: "-qq -pdsw225 -Dfar= ",
   108            suffix: ""
   109        };
   110    
   111        /*!
   112         *  ======== lnkOpts ========
   113         *  User configurable linker options.
   114         *
   115         *  Defaults:
   116         *  @p(dlist)
   117         *      -`-w`
   118         *          Display linker warnings
   119         *      -`-q`
   120         *          Quite run
   121         *      -`-u`
   122         *          Place unresolved external symbol into symbol table
   123         *      -`-c`
   124         *          ROM autoinitialization model
   125         *      -`-m`
   126         *          create a map file
   127         *      -`-l`
   128         *          archive library file as linker input
   129         */
   130        override config xdc.bld.ITarget2.Options lnkOpts = {
   131            prefix: "-w -q -u _c_int00",
   132            suffix: "-c -m $(XDCCFGDIR)/$@.map -l $(rootDir)/lib/rts55h.lib"
   133        };
   134    
   135        override config string includeOpts = "-I$(rootDir)/include";
   136    
   137        final override readonly config string sectMap[string] =
   138            ti.targets.C55.sectMap;
   139    
   140        override readonly config xdc.bld.ITarget.StdTypes stdTypes = {
   141            t_IArg          : { size: 2, align: 2 },
   142            t_Char          : { size: 1, align: 1 },
   143            t_Double        : { size: 2, align: 2 },
   144            t_Float         : { size: 2, align: 2 },
   145            t_Fxn           : { size: 2, align: 2 },
   146            t_Int           : { size: 1, align: 1 },
   147            t_Int8          : { size: 1, align: 1 },
   148            t_Int16         : { size: 1, align: 1 },
   149            t_Int32         : { size: 2, align: 2 },
   150            t_Int40         : { size: 4, align: 2 },
   151            t_Long          : { size: 2, align: 2 },
   152            t_LDouble       : { size: 2, align: 2 },
   153            t_LLong         : { size: 4, align: 2 },
   154            t_Ptr           : { size: 2, align: 2 },
   155            t_Short         : { size: 1, align: 1 },
   156            t_Size          : { size: 2, align: 2 },
   157        };
   158    
   159        override readonly config Int bitsPerChar = 16;
   160    
   161    }
   162    /*
   163     *  @(#) ti.targets; 1, 0, 3,399; 8-4-2010 16:21:18; /db/ztree/library/trees/xdctargets/xdctargets-c27x/src/
   164     */
   165