Skip to content

Instantly share code, notes, and snippets.

View ivan2029's full-sized avatar

Ivan Barišić ivan2029

  • Meteomatics AG
  • St Gallen
View GitHub Profile
#include <iostream>
#include <string>
#include <string_view>
#include <vector>
#include <variant>
#include <cassert>
using namespace std::string_view_literals;
namespace parser {
#include <iostream>
#include <string>
#include <string_view>
#include <cinttypes>
#include <algorithm>
#include <iterator>
#include <ranges>
#include <format>
#include <cassert>
#include <array>
// COPY FROM HERE ...
//
#include <chrono>
#include <string>
#include <string_view>
#include <sstream>
#include <iostream>
#include <thread>
#
# ~/.config/helix/config.toml
#
#theme = "autumn"
#theme = "monokai_pro"
theme = "monokai_pro_machine"
[editor]
rulers = [80]
bufferline = "always"
//
// g++-12 -o without_simd soa_aos.cpp -O3 -march=native -std=c++23 <tbb, fmt, and eve includes and libs>
// g++-12 -o without_simd soa_aos.cpp -O3 -march=native -std=c++23 -DUSE_SIMD <tbb, fmt, and eve includes and libs>
//
#include <vector>
#include <chrono>
#include <random>
#include <array>
#include <cstddef>
/*
compile with:
g++ -std=c++20 -c -S <this file>
Demonstrates why it's better to pass moveable object by value and not by const ref (when you want to have ownership).
And why it's all the same if object is trivially copyable.
*/
#include <vector>
#include <iostream>
#include <vector>
#include <queue>
#include <stack>
#include <span>
#include <ranges>
#include <concepts>
#include <cassert>
template<class T>
#include <iostream>
#include <chrono>
#include <utility>
#include <vector>
#include <cmath>
#include <random>
#include <numbers>
#include <memory>
using namespace std;
using namespace std::chrono;
/*
[dependencies]
anyhow = "1.0"
scopeguard = "1.1"
ash = { version = "0.35", features = ["loaded"] }
*/
use anyhow::Result;
use ash::{vk, Entry};
use scopeguard::defer;
;;
;; proxy, if you need one
;;
;;(setq url-proxy-services
;; '(("no_proxy" . "^\\(localhost\\|10.*\\)")
;; ("http" . "<write your proxy>:8080")
;; ("https" . "<write your proxy>:8080")))
;;