Войти в систему

Home
    - Создать дневник
    - Написать в дневник
       - Подробный режим

LJ.Rossia.org
    - Новости сайта
    - Общие настройки
    - Sitemap
    - Оплата
    - ljr-fif

Редактировать...
    - Настройки
    - Список друзей
    - Дневник
    - Картинки
    - Пароль
    - Вид дневника

Сообщества

Настроить S2

Помощь
    - Забыли пароль?
    - FAQ
    - Тех. поддержка



Пишет nancygold ([info]nancygold)
@ 2024-07-26 23:43:00


Previous Entry  Add to memories!  Tell a Friend!  Next Entry
Настроение: amused
Entry tags:computing

Surprisingly replacing

INLINE uint64_t PRFX(NH_PFX,,Hash_)(uint64_t key) {
  key ^= key >> 33;
  key *= 0xff51afd7ed558ccd;
  key ^= key >> 33;
  key *= 0xc4ceb9fe1a85ec53;
  key ^= key >> 33;
  return key;
}

with
INLINE uint64_t PRFX(NH_PFX,,Hash_)(uint64_t key) {
  return (key ^ (key >> 33)) * 0xff51afd7ed558ccd;
}

Makes the code setting 2**32 bits 20% faster.
Counter intuitive, since every one recommends stronger hash functions.
Guess that is another "security expert" thingie.
Because some hacker can spam your hashmap with collisions.
Which never happens in reality, because nobody cares about my apps.
Lesson learned: pay no attention to retards, especially renowned PhD retards.


(Читать комментарии) - (Добавить комментарий)


[info]nancygold
2024-07-27 00:56 (ссылка)
Exactly! Security is overrated.
But niggers will keep promoting it everywhere.
SSL was the worst thing happening to Internet.

(Ответить) (Уровень выше) (Ветвь дискуссии)


(Анонимно)
2024-07-27 01:09 (ссылка)
>SSL was the worst

Highly useful against non-technical neighbors trying to dig through your shit, and non-state actors in general.

(Ответить) (Уровень выше)


(Читать комментарии) -