Add asm generation for typical OOR_EQUAL_P functions

This commit is contained in:
Patrick Pelissier committed 2022-04-19 20:57:03 +02:00
1 parent 33ba602aef
commit 57b88160ae
1 file changed
+19
+19
View File
@@ -22,6 +22,7 @@
*/
#include <stdint.h>
#include "m-dict.h"
#include "m-string.h"
static inline bool my_oor_equal_p(uint64_t k, unsigned char n)
{
@@ -64,3 +65,21 @@ void clean(dict_t d)
{
dict_reset(d);
}
extern bool testempty(uint64_t d);
bool testempty(uint64_t d)
{
if (my_oor_equal_p(d, 0) || my_oor_equal_p(d, 1))
return true;
else
return false;
}
extern bool testempty2(string_t d);
bool testempty2(string_t d)
{
if (string_oor_equal_p(d, 0) || string_oor_equal_p(d, 1))
return true;
else
return false;
}