[PATCH 07/11] Add bitcount inlinesfor RTEMS. These are found in FREEBSDs types.h

Kirspel, Kevin Kevin-Kirspel at idexx.com
Tue May 16 12:15:14 UTC 2017


For now, could we just include this in rtems-libbsd until newlib gets updated?

Kevin Kirspel
Electrical Engineer - Sr. Staff
Idexx Roswell
235 Hembree Park Drive
Roswell GA 30076
Tel: (770)-510-4444 ext. 81642
Direct: (770)-688-1642
Fax: (770)-510-4445

-----Original Message-----
From: Sebastian Huber [mailto:sebastian.huber at embedded-brains.de] 
Sent: Tuesday, May 16, 2017 3:47 AM
To: Kirspel, Kevin <Kevin-Kirspel at idexx.com>; devel at rtems.org
Subject: Re: [PATCH 07/11] Add bitcount inlinesfor RTEMS. These are found in FREEBSDs types.h

Hello Kevin,

I know it is considerable more work, but this should move into Newlib.

The

#ifdef __POPCNT__
#define	__bitcount64(x)	__builtin_popcountll((__uint64_t)(x))

needs GCC support. This __POPCNT__ is a clang feature. I don't know which version of GCC supports these builtins, but it should use also a __GNUC_PREREQ__(X, Y).

--
Sebastian Huber, embedded brains GmbH

Address : Dornierstr. 4, D-82178 Puchheim, Germany
Phone   : +49 89 189 47 41-16
Fax     : +49 89 189 47 41-09
E-Mail  : sebastian.huber at embedded-brains.de
PGP     : Public key available on request.

Diese Nachricht ist keine geschäftliche Mitteilung im Sinne des EHUG.




More information about the devel mailing list