phoreproject / bls

Go implementation of the BLS12-381 pairing
Apache License 2.0
89 stars 31 forks source link

Does it support 32bit platform? #17

Closed Nanyan closed 4 years ago

Nanyan commented 4 years ago

Hi there. This project seems to be not supporting 32bit platforms, and I found that some uint64 numbers are converted to unit before doing some calculates in stub_fallback.go, such as in the func AddWithCarry.

Is there any special considerations here?

Thanks.

meyer9 commented 4 years ago

I think it can, but we'd have to switch it from bits.Add to bits.Add64

Nanyan commented 4 years ago

I've been making some test on it, it seems that by switching bits.Add to bits.Add64..., then it will working well both on 64bit and 32bit platforms.

So will you considering to update the code so that it can supports both 64bit os and 32bit os?