diff options
Diffstat (limited to 'src/lib/libcrypto/ppccpuid.pl')
-rwxr-xr-x | src/lib/libcrypto/ppccpuid.pl | 85 |
1 files changed, 0 insertions, 85 deletions
diff --git a/src/lib/libcrypto/ppccpuid.pl b/src/lib/libcrypto/ppccpuid.pl deleted file mode 100755 index 0cef7014b6..0000000000 --- a/src/lib/libcrypto/ppccpuid.pl +++ /dev/null | |||
@@ -1,85 +0,0 @@ | |||
1 | #!/usr/bin/env perl | ||
2 | |||
3 | $flavour = shift; | ||
4 | |||
5 | $0 =~ m/(.*[\/\\])[^\/\\]+$/; $dir=$1; | ||
6 | ( $xlate="${dir}ppc-xlate.pl" and -f $xlate ) or | ||
7 | ( $xlate="${dir}perlasm/ppc-xlate.pl" and -f $xlate) or | ||
8 | die "can't locate ppc-xlate.pl"; | ||
9 | |||
10 | open STDOUT,"| $^X $xlate $flavour ".shift || die "can't call $xlate: $!"; | ||
11 | |||
12 | if ($flavour=~/64/) { | ||
13 | $CMPLI="cmpldi"; | ||
14 | $SHRLI="srdi"; | ||
15 | $SIGNX="extsw"; | ||
16 | } else { | ||
17 | $CMPLI="cmplwi"; | ||
18 | $SHRLI="srwi"; | ||
19 | $SIGNX="mr"; | ||
20 | } | ||
21 | |||
22 | $code=<<___; | ||
23 | .machine "any" | ||
24 | .text | ||
25 | |||
26 | #if 0 | ||
27 | .globl .OPENSSL_ppc64_probe | ||
28 | .align 4 | ||
29 | .OPENSSL_ppc64_probe: | ||
30 | fcfid f1,f1 | ||
31 | extrdi r0,r0,32,0 | ||
32 | blr | ||
33 | .long 0 | ||
34 | .byte 0,12,0x14,0,0,0,0,0 | ||
35 | #endif | ||
36 | |||
37 | .globl .OPENSSL_wipe_cpu | ||
38 | .align 4 | ||
39 | .OPENSSL_wipe_cpu: | ||
40 | xor r0,r0,r0 | ||
41 | fmr f0,f31 | ||
42 | fmr f1,f31 | ||
43 | fmr f2,f31 | ||
44 | mr r3,r1 | ||
45 | fmr f3,f31 | ||
46 | xor r4,r4,r4 | ||
47 | fmr f4,f31 | ||
48 | xor r5,r5,r5 | ||
49 | fmr f5,f31 | ||
50 | xor r6,r6,r6 | ||
51 | fmr f6,f31 | ||
52 | xor r7,r7,r7 | ||
53 | fmr f7,f31 | ||
54 | xor r8,r8,r8 | ||
55 | fmr f8,f31 | ||
56 | xor r9,r9,r9 | ||
57 | fmr f9,f31 | ||
58 | xor r10,r10,r10 | ||
59 | fmr f10,f31 | ||
60 | xor r11,r11,r11 | ||
61 | fmr f11,f31 | ||
62 | xor r12,r12,r12 | ||
63 | fmr f12,f31 | ||
64 | fmr f13,f31 | ||
65 | blr | ||
66 | .long 0 | ||
67 | .byte 0,12,0x14,0,0,0,0,0 | ||
68 | |||
69 | .globl .OPENSSL_atomic_add | ||
70 | .align 4 | ||
71 | .OPENSSL_atomic_add: | ||
72 | Ladd: lwarx r5,0,r3 | ||
73 | add r0,r4,r5 | ||
74 | stwcx. r0,0,r3 | ||
75 | bne- Ladd | ||
76 | $SIGNX r3,r0 | ||
77 | blr | ||
78 | .long 0 | ||
79 | .byte 0,12,0x14,0,0,0,2,0 | ||
80 | .long 0 | ||
81 | ___ | ||
82 | |||
83 | $code =~ s/\`([^\`]*)\`/eval $1/gem; | ||
84 | print $code; | ||
85 | close STDOUT; | ||