Fwd: ppc64 %simple-bit-boole (fwd)

Gary Byers <[email protected]> Sun, 31 Jul 2005 18:21:45 -0600 (MDT)
Newsgroups gmane.lisp.openmcl.bugs
Message-ID <[email protected]>

---------- Forwarded message ----------
Date: Sun, 31 Jul 2005 16:52:32 -0700
From: bryan o'connor <[email protected]>
To: Gary Byers <[email protected]>
Subject: Fwd: ppc64 %simple-bit-boole

i'm not sure if bug-openmcl is working properly.  i never
received my message back nor saw it in the archives.

regardless, here was my initial bug report.. updated with
a patch.  while it fixes the bug, i'm not sure if it's the
right fix.

     ...bryan


> From: bryan o'connor <[email protected]>
> Date: July 31, 2005 4:34:55 PM PDT
> To: [email protected]
> Subject: ppc64 %simple-bit-boole
> 
> 
> i think the ppc64 version of %simple-bit-boole is skipping
> the last 4 bits.  i don't know enough ppc assembly to fix it.
> 
> ; ppc64
> ? (CCL::%SIMPLE-BIT-BOOLE 6 
> #*1111110001011011100110000101000101101011010111101011111000110010111 
> #*1111110101110010100011000111001001000010011111111010001000000011111 
> #*0000000000000000000000000000000000000000000000000000000000000000000)
> #*1111110001010010100010000101000001000010010111101010001000000010000
>                                                                  ^^^^
> ; ppc32
> (CCL::%SIMPLE-BIT-BOOLE 6 
> #*1111110001011011100110000101000101101011010111101011111000110010111 
> #*1111110101110010100011000111001001000010011111111010001000000011111 
> #*0000000000000000000000000000000000000000000000000000000000000000000)
> #*1111110001010010100010000101000001000010010111101010001000000010111
>                                                                  ^^^^

_______________________________________________
Bug-openmcl mailing list
[email protected]
http://clozure.com/mailman/listinfo/bug-openmcl
patch.txt (text/plain, 812 B)
Index: level-0/PPC/ppc-array.lisp
===================================================================
RCS file: /usr/local/tmpcvs/ccl-0.14-dev/ccl/level-0/PPC/ppc-array.lisp,v
retrieving revision 1.12
diff -u -c -r1.12 ppc-array.lisp
*** level-0/PPC/ppc-array.lisp	5 Jul 2005 10:12:49 -0000	1.12
--- level-0/PPC/ppc-array.lisp	31 Jul 2005 23:47:12 -0000
***************
*** 731,738 ****
    (la imm0 8 vsp)
    (save-lisp-context imm0)
    (vector-size imm4 result imm4)
!   (srdi. imm3 imm4 6)
!   (clrldi imm4 imm4 (- 64 6))
    (bl @get-dispatch)
    (cmpwi cr1 imm4 0)
    (mflr loc-pc)
--- 731,738 ----
    (la imm0 8 vsp)
    (save-lisp-context imm0)
    (vector-size imm4 result imm4)
!   (srdi. imm3 imm4 2)
!   (clrldi imm4 imm4 (- 64 2))
    (bl @get-dispatch)
    (cmpwi cr1 imm4 0)
    (mflr loc-pc)