The branch, master has been updated via ea58fe9a9ba494eca70014a0c6e51cc7880187c6 (commit) from ad36974015d8a9f2404e3deb5c537a8e8f89dea0 (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email. - Log ----------------------------------------------------------------- commit ea58fe9a9ba494eca70014a0c6e51cc7880187c6 Author: Andrew Cagney <cagney@redhat.com> Date: Thu Jun 5 13:01:46 2008 -0400 Fix ADD asm param order; add more assembler step cases. frysk-core/frysk/pkglibdir/ChangeLog 2008-06-05 Andrew Cagney <cagney@redhat.com> * funit-raise.S: Fix ADD parameter order. frysk-imports/include/ChangeLog 2008-06-05 Andrew Cagney <cagney@redhat.com> * frysk-asm.h (ADD, SUB): Fix i386 and x86-64 parameter order. ----------------------------------------------------------------------- Summary of changes: frysk-core/frysk/pkglibdir/ChangeLog | 4 +++ frysk-core/frysk/pkglibdir/funit-raise.S | 6 ++-- frysk-core/frysk/pkglibdir/funit-stepping-asm.S | 33 ++++++++++++++++++++++- frysk-imports/include/ChangeLog | 4 +++ frysk-imports/include/frysk-asm.h | 18 ++++++------ 5 files changed, 52 insertions(+), 13 deletions(-) First 500 lines of diff: diff --git a/frysk-core/frysk/pkglibdir/ChangeLog b/frysk-core/frysk/pkglibdir/ChangeLog index 870ed2a..60d3428 100644 --- a/frysk-core/frysk/pkglibdir/ChangeLog +++ b/frysk-core/frysk/pkglibdir/ChangeLog @@ -1,3 +1,7 @@ +2008-06-05 Andrew Cagney <cagney@redhat.com> + + * funit-raise.S: Fix ADD parameter order. + 2007-05-23 Teresa Thomas <tthomas@redhat.com> * funit-ctypes.c: New file. diff --git a/frysk-core/frysk/pkglibdir/funit-raise.S b/frysk-core/frysk/pkglibdir/funit-raise.S index 2256451..2241aae 100644 --- a/frysk-core/frysk/pkglibdir/funit-raise.S +++ b/frysk-core/frysk/pkglibdir/funit-raise.S @@ -1,6 +1,6 @@ // This file is part of the program FRYSK. // -// Copyright 2007 Red Hat Inc. +// Copyright 2007, 2008 Red Hat Inc. // Copyright 2007 (C) IBM // // FRYSK is free software; you can redistribute it and/or modify it @@ -90,7 +90,7 @@ RAISE_FUNCTION_START(term_sig_hup) LOAD_BYTE_IMMED(REG0, SYS_gettid) SYSCALL LOAD_BYTE_IMMED(REG1,0) - ADD(REG0,REG1) + ADD(REG1,REG0) LOAD_BYTE_IMMED(REG2,SIGHUP) LOAD_BYTE_IMMED(REG0, SYS_tkill) term_sig_hup_label: @@ -102,7 +102,7 @@ RAISE_FUNCTION_START(ign_sig_urg) LOAD_BYTE_IMMED(REG0, SYS_gettid) SYSCALL LOAD_BYTE_IMMED(REG1,0) - ADD(REG0,REG1) + ADD(REG1,REG0) LOAD_BYTE_IMMED(REG2,SIGURG) LOAD_BYTE_IMMED(REG0, SYS_tkill) ign_sig_urg_label: diff --git a/frysk-core/frysk/pkglibdir/funit-stepping-asm.S b/frysk-core/frysk/pkglibdir/funit-stepping-asm.S index c64f397..f145566 100644 --- a/frysk-core/frysk/pkglibdir/funit-stepping-asm.S +++ b/frysk-core/frysk/pkglibdir/funit-stepping-asm.S @@ -1,6 +1,6 @@ // This file is part of the program FRYSK. // -// Copyright 2006, 2007 Red Hat Inc. +// Copyright 2006, 2007, 2008 Red Hat Inc. // // FRYSK is free software; you can redistribute it and/or modify it // under the terms of the GNU General Public License as published by @@ -93,10 +93,41 @@ FUNCTION_EPILOGUE(first, 0) FUNCTION_RETURN(first, 0) FUNCTION_END(first, 0) +\f + + // A function that contains multiple function calls on a + // single line. + FUNCTION_BEGIN(multi,0) + FUNCTION_PROLOGUE(multi,0) + FUNCTION_CALL(fifth) // _multi_Call + NO_OP ; FUNCTION_CALL(fifth) // _multi_NopCall + FUNCTION_CALL(fifth) ; NO_OP // _multi_CallNop + NO_OP ; FUNCTION_CALL(fifth) ; NO_OP // _multi_NopCallNop + FUNCTION_CALL(fifth); FUNCTION_CALL(fifth) // _multi_CallCall + FUNCTION_EPILOGUE(multi,0) + FUNCTION_RETURN(multi,0) + FUNCTION_END(multi,0) +\f + // A function making recursive calls til R0 reaches 0, next + // shouldn't get confused by recursion. + FUNCTION_BEGIN(recursive,0) + FUNCTION_PROLOGUE(recursive,0) + LOAD_REGISTER_IMMED(REG1,0) + COMPARE(REG0, REG1) + JUMP_EQ(1f) + LOAD_REGISTER_IMMED(REG1,1) + SUB(REG0, REG1) + FUNCTION_CALL(recursive) // _recursive +1: + FUNCTION_EPILOGUE(recursive,0) + FUNCTION_RETURN(recursive,0) + FUNCTION_END(recursive,0) FUNCTION_BEGIN(main, 0) MAIN_PROLOGUE(0) FUNCTION_CALL(first) + FUNCTION_CALL(multi) + LOAD_REGISTER_IMMED(REG0, 2) ; FUNCTION_CALL(recursive) MAIN_EPILOGUE(0) FUNCTION_RETURN(main,0) FUNCTION_END(main,0) diff --git a/frysk-imports/include/ChangeLog b/frysk-imports/include/ChangeLog index a2efe0e..2b14368 100644 --- a/frysk-imports/include/ChangeLog +++ b/frysk-imports/include/ChangeLog @@ -1,3 +1,7 @@ +2008-06-05 Andrew Cagney <cagney@redhat.com> + + * frysk-asm.h (ADD, SUB): Fix i386 and x86-64 parameter order. + 2008-04-30 Andrew Cagney <cagney@redhat.com> * frysk-asm.h (VARIABLE): Rename WORD. diff --git a/frysk-imports/include/frysk-asm.h b/frysk-imports/include/frysk-asm.h index 86d38cb..e2520a1 100644 --- a/frysk-imports/include/frysk-asm.h +++ b/frysk-imports/include/frysk-asm.h @@ -339,31 +339,31 @@ // foo: #if defined __i386__ -# define ADD(DEST_REG, SOURCE_REG) addl DEST_REG, SOURCE_REG +# define ADD(DEST_REG, CONST_REG) addl CONST_REG, DEST_REG #elif defined __x86_64__ -# define ADD(DEST_REG, SOURCE_REG) addq DEST_REG, SOURCE_REG +# define ADD(DEST_REG, CONST_REG) addq CONST_REG, DEST_REG #elif defined __powerpc__ -# define ADD(DEST_REG, SOURCE_REG) add DEST_REG, DEST_REG, SOURCE_REG +# define ADD(DEST_REG, CONST_REG) add DEST_REG, DEST_REG, CONST_REG #else # warning "No register-add instruction defined" #endif #if defined __i386__ -# define SUB(DEST_REG, SOURCE_REG) subl DEST_REG, SOURCE_REG +# define SUB(DEST_REG, CONST_REG) subl CONST_REG, DEST_REG #elif defined __x86_64__ -# define SUB(DEST_REG, SOURCE_REG) subq DEST_REG, SOURCE_REG +# define SUB(DEST_REG, CONST_REG) subq CONST_REG, DEST_REG #elif defined __powerpc__ -# define SUB(DEST_REG, SOURCE_REG) subf DEST_REG, SOURCE_REG, DEST_REG +# define SUB(DEST_REG, CONST_REG) subf DEST_REG, CONST_REG, DEST_REG #else # warning "No register-subtract instruction defined" #endif #if defined __i386__ -# define MOVE(SOURCE_REG, DEST_REG) movl SOURCE_REG, DEST_REG +# define MOVE(CONST_REG, DEST_REG) movl CONST_REG, DEST_REG #elif defined __x86_64__ -# define MOVE(SOURCE_REG, DEST_REG) movq SOURCE_REG, DEST_REG +# define MOVE(CONST_REG, DEST_REG) movq CONST_REG, DEST_REG #elif defined __powerpc__ -# define MOVE(SOURCE_REG, DEST_REG) mr DEST_REG, SOURCE_REG +# define MOVE(CONST_REG, DEST_REG) mr DEST_REG, CONST_REG #else # warning "No register-move instruction defined" #endif hooks/post-receive -- frysk system monitor/debugger