You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
#defineNUMMAX 9 // largest number represented in num[]
922
920
#defineNUMMIN (~NUMMAX) // smallest number represented in num[]
923
921
// Given SZI B01s read into p, pack the bits into the MSBs of p and clear the lower bits of p
924
-
#ifC_LE// if anybody makes a bigendian CPU we'll have to recode
925
922
#ifBW==64
926
923
// this is what it should be #define PACKBITS(p) {p|=p>>7LL;p|=p>>14LL;p|=p>>28LL;p<<=56LL;}
927
924
#definePACKBITS(p) {p|=p>>7LL;p|=p>>14LL;p|=p<<28LL;p&=0xff0000000; p<<=28LL;} // this generates one extra instruction, rather than the 3 for the correct version
928
925
#definePACKBITSINTO(p,out) {p|=p>>7LL;p|=p>>14LL;out=((p|(p>>28LL))<<56)|(out>>SZI);} // pack and shift into out
#definePRISTCOMSETF(w,flg) if(unlikely((flg&AFVIRTUAL)!=0)){w=ABACK(w); flg=AFLAG(w);} AFLAG(w)=flg&~AFPRISTINE; // used only at end, when w can be destroyed
@@ -1057,10 +1050,8 @@ if(likely(z<3)){_zzt+=z; z=(I)&oneone; _zzt=_i&3?_zzt:(I*)z; z=_i&2?(I)_zzt:z; z
// Input is the name of word of bytes. Result is modified name, 1 bit per input byte, spaced like B01s, with the bit 0 iff the corresponding input byte was all 0. Non-boolean bits of result are garbage.
1065
1056
#defineZBYTESTOZBITS(b) (b=b|((b|(~b+VALIDBOOLEAN))>>7)) // for each byte: zero if b0 off, b7 off, and b7 turns on when you subtract 1 or 2
1066
1057
// to verify gah conversion #define RETF(exp) { A retfff=(exp); if ((retfff) && ((AT(retfff)&SPARSE && AN(retfff)!=1) || (AT(retfff)&DENSE && AN(retfff)!=prod(AR(retfff),AS(retfff)))))SEGFAULT;; R retfff; } // scaf
@@ -1099,7 +1090,6 @@ if(likely(z<3)){_zzt+=z; z=(I)&oneone; _zzt=_i&3?_zzt:(I*)z; z=_i&2?(I)_zzt:z; z
1099
1090
#defineVAL2 '\002'
1100
1091
#defineWITHDEBUGOFF(stmt) {UC d=jt->uflags.us.cx.cx_c.db; jt->uflags.us.cx.cx_c.db=0; stmt jt->uflags.us.cx.cx_c.db=d;} // execute stmt with debug turned off
1101
1092
1102
-
#ifC_LE
1103
1093
#ifBW==64
1104
1094
#defineIHALF0 0x00000000ffffffffLL
1105
1095
#else
@@ -1125,39 +1115,9 @@ if(likely(z<3)){_zzt+=z; z=(I)&oneone; _zzt=_i&3?_zzt:(I*)z; z=_i&2?(I)_zzt:z; z
1125
1115
#defineBS01 0x0100
1126
1116
#defineBS10 0x0001
1127
1117
#defineBS11 0x0101
1128
-
#else
1129
-
#ifBW==64
1130
-
#defineIHALF0 0xffffffff00000000LL
1131
-
#else
1132
-
#defineIHALF0 0xffff0000
1133
-
#endif
1134
-
#defineB0000 0x00000000
1135
-
#defineB0001 0x00000001
1136
-
#defineB0010 0x00000100
1137
-
#defineB0011 0x00000101
1138
-
#defineB0100 0x00010000
1139
-
#defineB0101 0x00010001
1140
-
#defineB0110 0x00010100
1141
-
#defineB0111 0x00010101
1142
-
#defineB1000 0x01000000
1143
-
#defineB1001 0x01000001
1144
-
#defineB1010 0x01000100
1145
-
#defineB1011 0x01000101
1146
-
#defineB1100 0x01010000
1147
-
#defineB1101 0x01010001
1148
-
#defineB1110 0x01010100
1149
-
#defineB1111 0x01010101
1150
-
#defineBS00 0x0000
1151
-
#defineBS01 0x0001
1152
-
#defineBS10 0x0100
1153
-
#defineBS11 0x0101
1154
-
#endif
1155
-
1156
-
1157
1118
1158
1119
#defineCACHELINESIZE 64 // size of processor cache line, in case we align to it
1159
1120
1160
-
1161
1121
// flags in call to cachedmmult and blockedmmult
1162
1122
#defineFLGCMPX 0
1163
1123
#defineFLGCMP ((I)1<<FLGCMPX) // arguments are complex
0 commit comments