Anúncio
Anúncio

Mais conteúdo relacionado

Último(20)

Anúncio

C++20 Attributes [[likely]] and [[unlikely]]

  1. Attributes [[likely]] and [[unlikely]]
  2. 선언문을 제외한 label 과 statements 에서 최적화를 위해 사용 (https://wikidocs.net/51311) [[likely]] : 빈도가 높음 [[unlikely]] : 빈도가 낮음
  3. case 2 인 경우에는 최적화가 되지만 case 1 인 경우에는 최적화되지 않는다. (fallthrough 무시)
  4. 성능 비교 https://en.cppreference.com/w/cpp/language/attributes/likely
Anúncio