tramp.c (MOVHI, ORI, JMP): Conditionalize for __nios2_arch__ level.
2015-07-14 Sandra Loosemore <sandra@codesourcery.com> Cesar Philippidis <cesar@codesourcery.com> Chung-Lin Tang <cltang@codesourcery.com> libgcc/ * config/nios2/tramp.c (MOVHI, ORI, JMP): Conditionalize for __nios2_arch__ level. Co-Authored-By: Cesar Philippidis <cesar@codesourcery.com> Co-Authored-By: Chung-Lin Tang <cltang@codesourcery.com> From-SVN: r225794
This commit is contained in:
parent
973590f320
commit
a03c6ae388
2 changed files with 24 additions and 3 deletions
|
@ -1,3 +1,10 @@
|
|||
2015-07-14 Sandra Loosemore <sandra@codesourcery.com>
|
||||
Cesar Philippidis <cesar@codesourcery.com>
|
||||
Chung-Lin Tang <cltang@codesourcery.com>
|
||||
|
||||
* config/nios2/tramp.c (MOVHI, ORI, JMP): Conditionalize
|
||||
for __nios2_arch__ level.
|
||||
|
||||
2015-07-13 John Marino <gnugcc@marino.st>
|
||||
|
||||
* config/i386/t-dragonfly: New.
|
||||
|
|
|
@ -33,13 +33,27 @@ see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
|
|||
|
||||
#define SC_REGNO 12
|
||||
|
||||
#define MOVHI(reg,imm16) \
|
||||
/* Instruction encodings depend on the ISA level. */
|
||||
#if __nios2_arch__ == 2
|
||||
#define MOVHI(reg,imm16) \
|
||||
(((reg) << 11) | ((imm16) << 16) | 0x34)
|
||||
#define ORI(reg,imm16) \
|
||||
(((reg) << 11) | ((reg) << 6) | ((imm16) << 16) | 0x14)
|
||||
#define JMP(reg) \
|
||||
(((reg) << 6) | (0x0d << 26) | 0x20)
|
||||
|
||||
#elif __nios2_arch__ == 1
|
||||
#define MOVHI(reg,imm16) \
|
||||
(((reg) << 22) | ((imm16) << 6) | 0x34)
|
||||
#define ORI(reg,imm16) \
|
||||
#define ORI(reg,imm16) \
|
||||
(((reg) << 27) | ((reg) << 22) | ((imm16) << 6) | 0x14)
|
||||
#define JMP(reg) \
|
||||
#define JMP(reg) \
|
||||
(((reg) << 27) | (0x0d << 11) | 0x3a)
|
||||
|
||||
#else
|
||||
#error "Unknown Nios II architecture level"
|
||||
#endif
|
||||
|
||||
void
|
||||
__trampoline_setup (unsigned int *addr, void *fnptr, void *chainptr)
|
||||
{
|
||||
|
|
Loading…
Add table
Reference in a new issue