On 15/03/15 15:14, Jean-Pierre Münch wrote:
> Hey everyone,
> 
> as you guys have noticed I'm very bad with ASM/SSE/... code.
> So I'm here and asking you how to reformulate the following code into 
> Crypto++'s style, so that'll run everywhere (-> Windows, Linux, ...)
> (Note: This code is taken from here 
> <https://software.intel.com/en-us/articles/intel-digital-random-number-generator-drng-software-implementation-guide>,
>  
> code example 3)
> 
> 13int rdrand32_step (uint32_t *rand)
> 14{
> 15    unsigned char ok;
> 16 
> 17    asm volatile ("rdrand %0; setc %1"
> 18        : "=r" (*rand), "=qm" (ok));
> 19 
> 20    return (int) ok;
> 21}

Please do note that you have to have a CPU agnostic implementation too.
People are running Crypto++ on Android, SPARC, etc.

I do not have any x86 knowledge though (only some vague 8080), so can't
help with the problem.

-- 
-- 
You received this message because you are subscribed to the "Crypto++ Users" 
Google Group.
To unsubscribe, send an email to [email protected].
More information about Crypto++ and this group is available at 
http://www.cryptopp.com.
--- 
You received this message because you are subscribed to the Google Groups 
"Crypto++ Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Attachment: signature.asc
Description: OpenPGP digital signature

Reply via email to