This is the mail archive of the cgen@sourceware.org mailing list for the CGEN project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[patch][commit] Typo in utils-sim.scm Generating Decoder


Hi,

I've committed this patch which corrects a typo in the generation of the decoder. The generated code was intended to shift 'entire_insn' to the right when the insn length is less than the base insn size.

Tested on an internal port which exposed the problem.

Dave
2006-05-09  Dave Brolley  <brolley@redhat.com>

	* utils-sim.scm (-gen-decode-insn-entry): Generated code should shift
	'entire_insn' not 'base_insn'.
Index: cgen/utils-sim.scm
===================================================================
RCS file: /cvs/src/src/cgen/utils-sim.scm,v
retrieving revision 1.14
diff -c -p -r1.14 utils-sim.scm
*** cgen/utils-sim.scm	5 Dec 2005 01:27:23 -0000	1.14
--- cgen/utils-sim.scm	9 May 2006 18:39:16 -0000
***************
*** 1,5 ****
  ; Generic simulator application utilities.
! ; Copyright (C) 2000, 2005 Red Hat, Inc.
  ; This file is part of CGEN.
  ; See file COPYING.CGEN for details.
  
--- 1,5 ----
  ; Generic simulator application utilities.
! ; Copyright (C) 2000, 2005, 2006 Red Hat, Inc.
  ; This file is part of CGEN.
  ; See file COPYING.CGEN for details.
  
***************
*** 631,637 ****
  		     (if (and (equal? APPLICATION 'SID-SIMULATOR)
  			      (> (state-base-insn-bitsize) (insn-length insn)))
  			 (string-append
! 			  indent "    entire_insn = base_insn >> "
  			  (number->string (- (state-base-insn-bitsize) (insn-length insn)))
  			  ";\n")
  			 "")
--- 631,637 ----
  		     (if (and (equal? APPLICATION 'SID-SIMULATOR)
  			      (> (state-base-insn-bitsize) (insn-length insn)))
  			 (string-append
! 			  indent "    entire_insn = entire_insn >> "
  			  (number->string (- (state-base-insn-bitsize) (insn-length insn)))
  			  ";\n")
  			 "")

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]