Skip to content

Instantly share code, notes, and snippets.

View zao's full-sized avatar

Lars Viklund zao

View GitHub Profile
@zao
zao / fine-with-intel.cc
Created December 2, 2014 14:09
Function resolution in bind
#include <functional>
#include <string>
template <typename T>
bool fun(T, T, bool = 1, bool = 1) {
return true;
}
int main() {
std::string s;
@zao
zao / menvadihelvete.cc
Created December 12, 2014 21:58
table building hack
#define MAKE_TABLE \
BUILD_TABLE_ENTRY(50, 1) \
BUILD_TABLE_ENTRY(100, 2) \
BUILD_TABLE_ENTRY(250, 5) \
BUILD_TABLE_ENTRY(500, 10) \
BUILD_TABLE_ENTRY(1500, 30) \
BUILD_TABLE_ENTRY(3000, 1*60) \
BUILD_TABLE_ENTRY(6000, 2*60) \
BUILD_TABLE_ENTRY(15000, 5*60) \
BUILD_TABLE_ENTRY(30000, 10*60) \
@zao
zao / gw
Created January 8, 2015 14:41
traces to link
[lars@fnutt ~]$ tracepath6 2001:1608:10:155::1
1?: [LOCALHOST] 0.050ms pmtu 1500
1: 2001:6b0:e:4a46::1 0.424ms
1: 2001:6b0:e:4a46::1 0.387ms
2: 2001:6b0:e::205b 0.406ms
3: umu-br2.sunet.se 26.536ms
4: t1tug-ge-5-2-0.sunet.se 12.872ms asymm 5
5: se-tug.nordu.net 12.406ms asymm 6
6: se-fre.nordu.net 12.673ms
7: 2001:2000:3080:e::1 13.312ms
@zao
zao / CMakeLog.txt
Created February 14, 2015 14:10
CMake log
C:\Code\build-mot>Q:\Scripts\ci.cmd
-- The C compiler identification is MSVC 18.0.31101.0
-- The CXX compiler identification is MSVC 18.0.31101.0
-- Check for working C compiler using: Visual Studio 12 Win64
-- Check for working C compiler using: Visual Studio 12 Win64 -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working CXX compiler using: Visual Studio 12 Win64
-- Check for working CXX compiler using: Visual Studio 12 Win64 -- works
-- Detecting CXX compiler ABI info
@zao
zao / dagur-box.txt
Created February 19, 2015 00:08
Boxstarter for dagur
Set-StartScreenOptions -EnableBootToDesktop -EnableDesktopBackgroundOnStart
Set-CornerNavigationOptions -DisableUpperRightCornerShowCharms -DisableUpperLeftCornerSwitchApps
Set-WindowsExplorerOptions -EnableShowHiddenFilesFoldersDrives -EnableShowProtectedOSFiles -EnableShowFileExtensions -EnableShowFullPathInTitleBar
Enable-RemoteDesktop
# Note that this does not uncheck the only-secure-hosts checkbox.
cinst sublimetext3
cinst sublimetext3.packagecontrol
cinst virtualclonedrive
cinst mpc-hc
@zao
zao / Main.cc
Last active August 29, 2015 14:16
CH Skeleton
#include <MathGeoLib/MathGeoLib.h>
#include <Windows.h>
#include <deque>
#include <set>
#include <sstream>
#include <vector>
namespace skeleton
{
#!/usr/bin/env perl
use strict;
use warnings;
use v5.10;
my $fxc = "C:\\Program Files (x86)\\Windows Kits\\8.1\\bin\\x64\\fxc.exe";
system($fxc, qw( testVS.hlsl /O3 /Zi /Fo Z:\\public_html\\fvd\\test.vs.cso /nologo /T vs_5_0 /E main ));
die "vs compile failed: $?" if $?;
system($fxc, qw( testPS.hlsl /O3 /Zi /Fo Z:\\public_html\\fvd\\test.ps.cso /nologo /T ps_5_0 /E main ));
@zao
zao / build.log
Created July 22, 2015 05:38
HPX master, Boost master, VS 2015 RTM
1>------ Build started: Project: ZERO_CHECK, Configuration: RelWithDebInfo x64 ------
1> Checking Build System
1> CMake does not need to re-run because C:/hpx-3/build-hpx/CMakeFiles/generate.stamp is up-to-date.
1> CMake does not need to re-run because C:/hpx-3/build-hpx/plugins/CMakeFiles/generate.stamp is up-to-date.
1> CMake does not need to re-run because C:/hpx-3/build-hpx/plugins/binary_filter/CMakeFiles/generate.stamp is up-to-date.
1> CMake does not need to re-run because C:/hpx-3/build-hpx/plugins/binary_filter/bzip2/CMakeFiles/generate.stamp is up-to-date.
1> CMake does not need to re-run because C:/hpx-3/build-hpx/plugins/binary_filter/snappy/CMakeFiles/generate.stamp is up-to-date.
1> CMake does not need to re-run because C:/hpx-3/build-hpx/plugins/binary_filter/zlib/CMakeFiles/generate.stamp is up-to-date.
1> CMake does not need to re-run because C:/hpx-3/build-hpx/plugins/parcel/CMakeFiles/generate.stamp is up-to-date.
1> CMake does not need to re-run because C:/hpx-3/build-hpx/plugins/
@zao
zao / gist:bf6e0d024ba76d104534
Created July 22, 2015 05:54
HPX master, Boost master, VS 2015 RTM, failed subset
1>------ Skipped Build: Project: RUN_TESTS, Configuration: RelWithDebInfo x64 ------
1>Project not selected to build for this solution configuration
2>------ Build started: Project: cmake_build_dir_test.make_build_dir, Configuration: RelWithDebInfo x64 ------
3>------ Build started: Project: cmake_install_dir_test.make_build_dir, Configuration: RelWithDebInfo x64 ------
4>------ Build started: Project: vector_counting_dotproduct_exe, Configuration: RelWithDebInfo x64 ------
4> vector_counting_dotproduct.cpp
4> Unknown compiler version - please run the configure tests and report the results
4>c:\hpx-3\opt\boost-master\include\boost-1_59\boost\asio\detail\config.hpp(227): warning C4005: 'BOOST_ASIO_ERROR_CATEGORY_NOEXCEPT': macro redefinition
4> c:\hpx-3\opt\boost-master\include\boost-1_59\boost\asio\detail\config.hpp(213): note: see previous definition of 'BOOST_ASIO_ERROR_CATEGORY_NOEXCEPT'
4>c:\hpx-3\hpx\hpx\parallel\algorithms\transform_reduce.hpp(90): error C2440: '<function-style-cast>': cannot conver
@zao
zao / 9,12.log
Last active August 29, 2015 14:25
cmake_install_dir_test.make_configure, cmake_build_dir_test.make_configure
9>------ Build started: Project: cmake_install_dir_test.make_configure, Configuration: RelWithDebInfo x64 ------
9> Building Custom Rule C:/hpx-3/hpx/tests/unit/build/CMakeLists.txt
9> CMake does not need to re-run because C:\hpx-3\build-hpx-v120\tests\unit\build\CMakeFiles\generate.stamp is up-to-date.
9> -- Building for: Visual Studio 14 2015
9>
9> -- The CXX compiler identification is MSVC 19.0.23026.0
9>
9> -- Check for working CXX compiler using: Visual Studio 14 2015
9>
9> -- Check for working CXX compiler using: Visual Studio 14 2015 -- works