Skip to content

Instantly share code, notes, and snippets.

@sumproxy
Created July 2, 2015 13:54
Show Gist options
  • Save sumproxy/ce8826ce137cd3c36323 to your computer and use it in GitHub Desktop.
Save sumproxy/ce8826ce137cd3c36323 to your computer and use it in GitHub Desktop.
mrarth1.c:688:26: warning: shift count >= width of type [-Wshift-count-overflow]
z->w[i]|=(lsb<<(MIRACL-1));
^ ~~~~~~~~~~
1 warning generated.
mrcore.c:625:17: warning: shift count >= width of type [-Wshift-count-overflow]
temp=MR_DIV(MAXBASE,nb);
~~~~~~~^~~~~~~~~~~
../include/mirdef.h:28:29: note: expanded from macro 'MAXBASE'
#define MAXBASE ((mr_small)1<<(MIRACL-1))
^
../include/miracl.h:287:28: note: expanded from macro 'MR_DIV'
#define MR_DIV(a,b) ((a)/(b))
^
mrcore.c:789:49: warning: shift count >= width of type [-Wshift-count-overflow]
x->w[m++]=(mr_small)(n%((mr_dltype)1<<(MIRACL)));
^ ~~~~~~~~
mrcore.c:790:29: warning: shift count >= width of type [-Wshift-count-overflow]
n/=((mr_dltype)1<<(MIRACL));
^ ~~~~~~~~
mrcore.c:1139:21: warning: shift count >= width of type [-Wshift-count-overflow]
if (nb==1 || nb>MAXBASE)
^~~~~~~
../include/mirdef.h:28:29: note: expanded from macro 'MAXBASE'
#define MAXBASE ((mr_small)1<<(MIRACL-1))
^ ~~~~~~~~~~
4 warnings generated.
mrgf2m.c:353:15: warning: shift count >= width of type [-Wshift-count-overflow]
i=(int)((b>>32)&0xF); j=(int)((b>>36)&0xF);
^ ~~
mrgf2m.c:353:37: warning: shift count >= width of type [-Wshift-count-overflow]
i=(int)((b>>32)&0xF); j=(int)((b>>36)&0xF);
^ ~~
mrgf2m.c:358:15: warning: shift count >= width of type [-Wshift-count-overflow]
i=(int)((b>>40)&0xF); j=(int)((b>>44)&0xF);
^ ~~
mrgf2m.c:358:37: warning: shift count >= width of type [-Wshift-count-overflow]
i=(int)((b>>40)&0xF); j=(int)((b>>44)&0xF);
^ ~~
mrgf2m.c:363:15: warning: shift count >= width of type [-Wshift-count-overflow]
i=(int)((b>>48)&0xF); j=(int)((b>>52)&0xF);
^ ~~
mrgf2m.c:363:37: warning: shift count >= width of type [-Wshift-count-overflow]
i=(int)((b>>48)&0xF); j=(int)((b>>52)&0xF);
^ ~~
mrgf2m.c:368:15: warning: shift count >= width of type [-Wshift-count-overflow]
i=(int)((b>>56)&0xF); j=(int)(b>>60);
^ ~~
mrgf2m.c:368:36: warning: shift count >= width of type [-Wshift-count-overflow]
i=(int)((b>>56)&0xF); j=(int)(b>>60);
^ ~~
mrgf2m.c:545:27: warning: shift count >= width of type [-Wshift-count-overflow]
mr_small *gx=x->w,bit=TOPBIT;
^~~~~~
../include/miracl.h:229:28: note: expanded from macro 'TOPBIT'
#define TOPBIT ((mr_small)1<<M1)
^ ~~
mrgf2m.c:647:19: warning: shift count >= width of type [-Wshift-count-overflow]
{0,(mr_small)1<<M8,(mr_small)4<<M8,(mr_small)5<<M8,(mr_small)16<<M8,
^ ~~
mrgf2m.c:647:35: warning: shift count >= width of type [-Wshift-count-overflow]
{0,(mr_small)1<<M8,(mr_small)4<<M8,(mr_small)5<<M8,(mr_small)16<<M8,
^ ~~
mrgf2m.c:647:51: warning: shift count >= width of type [-Wshift-count-overflow]
{0,(mr_small)1<<M8,(mr_small)4<<M8,(mr_small)5<<M8,(mr_small)16<<M8,
^ ~~
mrgf2m.c:647:68: warning: shift count >= width of type [-Wshift-count-overflow]
{0,(mr_small)1<<M8,(mr_small)4<<M8,(mr_small)5<<M8,(mr_small)16<<M8,
^ ~~
mrgf2m.c:648:17: warning: shift count >= width of type [-Wshift-count-overflow]
(mr_small)17<<M8,(mr_small)20<<M8,(mr_small)21<<M8,(mr_small)64<<M8,
^ ~~
mrgf2m.c:648:34: warning: shift count >= width of type [-Wshift-count-overflow]
(mr_small)17<<M8,(mr_small)20<<M8,(mr_small)21<<M8,(mr_small)64<<M8,
^ ~~
mrgf2m.c:648:51: warning: shift count >= width of type [-Wshift-count-overflow]
(mr_small)17<<M8,(mr_small)20<<M8,(mr_small)21<<M8,(mr_small)64<<M8,
^ ~~
mrgf2m.c:648:68: warning: shift count >= width of type [-Wshift-count-overflow]
(mr_small)17<<M8,(mr_small)20<<M8,(mr_small)21<<M8,(mr_small)64<<M8,
^ ~~
mrgf2m.c:649:17: warning: shift count >= width of type [-Wshift-count-overflow]
(mr_small)65<<M8,(mr_small)68<<M8,(mr_small)69<<M8,(mr_small)80<<M8,
^ ~~
mrgf2m.c:649:34: warning: shift count >= width of type [-Wshift-count-overflow]
(mr_small)65<<M8,(mr_small)68<<M8,(mr_small)69<<M8,(mr_small)80<<M8,
^ ~~
mrgf2m.c:649:51: warning: shift count >= width of type [-Wshift-count-overflow]
(mr_small)65<<M8,(mr_small)68<<M8,(mr_small)69<<M8,(mr_small)80<<M8,
^ ~~
mrgf2m.c:649:68: warning: shift count >= width of type [-Wshift-count-overflow]
(mr_small)65<<M8,(mr_small)68<<M8,(mr_small)69<<M8,(mr_small)80<<M8,
^ ~~
mrgf2m.c:650:17: warning: shift count >= width of type [-Wshift-count-overflow]
(mr_small)81<<M8,(mr_small)84<<M8,(mr_small)85<<M8};
^ ~~
mrgf2m.c:650:34: warning: shift count >= width of type [-Wshift-count-overflow]
(mr_small)81<<M8,(mr_small)84<<M8,(mr_small)85<<M8};
^ ~~
mrgf2m.c:650:51: warning: shift count >= width of type [-Wshift-count-overflow]
(mr_small)81<<M8,(mr_small)84<<M8,(mr_small)85<<M8};
^ ~~
mrgf2m.c:1829:25: warning: shift count >= width of type [-Wshift-count-overflow]
gx[i-16]^=(w<<56);
^ ~~
mrgf2m.c:1831:25: warning: shift count >= width of type [-Wshift-count-overflow]
gx[i-20]^=(w<<57);
^ ~~
mrgf2m.c:1834:20: warning: shift count >= width of type [-Wshift-count-overflow]
gx[3]^=(top<<56);
^ ~~
mrgf2m.c:1847:24: warning: shift count >= width of type [-Wshift-count-overflow]
gx[i-1]^=(w>>62);
^ ~~
mrgf2m.c:1849:24: warning: shift count >= width of type [-Wshift-count-overflow]
gx[i-5]^=(w>>59)^w;
^ ~~
mrgf2m.c:1852:18: warning: shift count >= width of type [-Wshift-count-overflow]
top=gx[5]>>59; gx[0]^=top; top<<=59;
^ ~~
mrgf2m.c:1852:39: warning: shift count >= width of type [-Wshift-count-overflow]
top=gx[5]>>59; gx[0]^=top; top<<=59;
^ ~~
mrgf2m.c:1855:20: warning: shift count >= width of type [-Wshift-count-overflow]
gx[4]^=(top>>62);
^ ~~
mrgf2m.c:2601:47: warning: shift count >= width of type [-Wshift-count-overflow]
we|=evens[((w&0x5)+((w&0x50)>>3))]<<32;
^ ~~
mrgf2m.c:2602:46: warning: shift count >= width of type [-Wshift-count-overflow]
wo|=odds[((w&0xA)+((w&0xA0)>>5))]<<32;
^ ~~
mrgf2m.c:2604:47: warning: shift count >= width of type [-Wshift-count-overflow]
we|=evens[((w&0x5)+((w&0x50)>>3))]<<36;
^ ~~
mrgf2m.c:2605:46: warning: shift count >= width of type [-Wshift-count-overflow]
wo|=odds[((w&0xA)+((w&0xA0)>>5))]<<36;
^ ~~
mrgf2m.c:2607:47: warning: shift count >= width of type [-Wshift-count-overflow]
we|=evens[((w&0x5)+((w&0x50)>>3))]<<40;
^ ~~
mrgf2m.c:2608:46: warning: shift count >= width of type [-Wshift-count-overflow]
wo|=odds[((w&0xA)+((w&0xA0)>>5))]<<40;
^ ~~
mrgf2m.c:2610:47: warning: shift count >= width of type [-Wshift-count-overflow]
we|=evens[((w&0x5)+((w&0x50)>>3))]<<44;
^ ~~
mrgf2m.c:2611:46: warning: shift count >= width of type [-Wshift-count-overflow]
wo|=odds[((w&0xA)+((w&0xA0)>>5))]<<44;
^ ~~
mrgf2m.c:2613:47: warning: shift count >= width of type [-Wshift-count-overflow]
we|=evens[((w&0x5)+((w&0x50)>>3))]<<48;
^ ~~
mrgf2m.c:2614:46: warning: shift count >= width of type [-Wshift-count-overflow]
wo|=odds[((w&0xA)+((w&0xA0)>>5))]<<48;
^ ~~
mrgf2m.c:2616:47: warning: shift count >= width of type [-Wshift-count-overflow]
we|=evens[((w&0x5)+((w&0x50)>>3))]<<52;
^ ~~
mrgf2m.c:2617:46: warning: shift count >= width of type [-Wshift-count-overflow]
wo|=odds[((w&0xA)+((w&0xA0)>>5))]<<52;
^ ~~
mrgf2m.c:2619:47: warning: shift count >= width of type [-Wshift-count-overflow]
we|=evens[((w&0x5)+((w&0x50)>>3))]<<56;
^ ~~
mrgf2m.c:2620:46: warning: shift count >= width of type [-Wshift-count-overflow]
wo|=odds[((w&0xA)+((w&0xA0)>>5))]<<56;
^ ~~
mrgf2m.c:2622:47: warning: shift count >= width of type [-Wshift-count-overflow]
we|=evens[((w&0x5)+((w&0x50)>>3))]<<60;
^ ~~
mrgf2m.c:2623:46: warning: shift count >= width of type [-Wshift-count-overflow]
wo|=odds[((w&0xA)+((w&0xA0)>>5))]<<60;
^ ~~
mrgf2m.c:2627:29: warning: shift count >= width of type [-Wshift-count-overflow]
y->w[10+n-1]^=wo<<36;
^ ~~
mrgf2m.c:2858:21: warning: shift count >= width of type [-Wshift-count-overflow]
bit=TOPBIT;
^~~~~~
../include/miracl.h:229:28: note: expanded from macro 'TOPBIT'
#define TOPBIT ((mr_small)1<<M1)
^ ~~
50 warnings generated.
mrmonty.c:145:20: warning: shift count >= width of type [-Wshift-count-overflow]
if (n->w[n->len-1]>>M4 < 5) mr_mip->NO_CARRY=TRUE;
^ ~~
1 warning generated.
mrxgcd.c:80:13: warning: shift count >= width of type [-Wshift-count-overflow]
if (lq>=MAXBASE) return 0;
^~~~~~~
../include/mirdef.h:28:29: note: expanded from macro 'MAXBASE'
#define MAXBASE ((mr_small)1<<(MIRACL-1))
^ ~~~~~~~~~~
mrxgcd.c:299:40: warning: shift count >= width of type [-Wshift-count-overflow]
if ((mr_small)(b+d) >= MAXBASE) break;
^~~~~~~
../include/mirdef.h:28:29: note: expanded from macro 'MAXBASE'
#define MAXBASE ((mr_small)1<<(MIRACL-1))
^ ~~~~~~~~~~
mrxgcd.c:306:31: warning: shift count >= width of type [-Wshift-count-overflow]
if (q>=MR_DIV(MAXBASE-b,d)) break;
~~~~~~~^~~~~~~~~~~~
../include/mirdef.h:28:29: note: expanded from macro 'MAXBASE'
#define MAXBASE ((mr_small)1<<(MIRACL-1))
^
../include/miracl.h:287:28: note: expanded from macro 'MR_DIV'
#define MR_DIV(a,b) ((a)/(b))
^
3 warnings generated.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment