Skip to content

Instantly share code, notes, and snippets.

View vedranmiletic's full-sized avatar

Vedran Miletić vedranmiletic

View GitHub Profile
@vedranmiletic
vedranmiletic / gist:5736544
Created June 8, 2013 20:53
git gui error on Remove Remote
unknown option "-label"
unknown option "-label"
while executing
"$fetch_m entrycget end -label"
(procedure "update_all_remotes_menu_entry" line 26)
invoked from within
"update_all_remotes_menu_entry"
(procedure "remove_remote" line 23)
invoked from within
"remove_remote bb"
@vedranmiletic
vedranmiletic / gist:0838afc9337564843439
Last active August 29, 2015 14:07
SphericalVector2D and SphericalVector3D
diff --git a/src/core/model/vector.cc b/src/core/model/vector.cc
--- a/src/core/model/vector.cc
+++ b/src/core/model/vector.cc
@@ -29,12 +29,19 @@
ATTRIBUTE_HELPER_CPP (Vector3D);
ATTRIBUTE_HELPER_CPP (Vector2D);
+ATTRIBUTE_HELPER_CPP (SphericalVector3D);
+ATTRIBUTE_HELPER_CPP (SphericalVector2D);
// compatibility for mobility code
@vedranmiletic
vedranmiletic / gist:1ff0f120cf46421086c0
Created December 20, 2014 20:43
kernel oops on upgrading nvidia-driver and installing nvidia-cuda-toolkit
[ 2341.946239] BUG: unable to handle kernel paging request at ffffffffa16429b8
[ 2341.946386] IP: [<ffffffff81204790>] proc_get_inode+0xd0/0x130
[ 2341.946493] PGD 1816067 PUD 1817063 PMD b8d4a067 PTE 0
[ 2341.946720] Oops: 0000 [#1] SMP
[ 2341.946887] Modules linked in: cfg80211 rfkill nfsd auth_rpcgss oid_registry nfs_acl nfs lockd fscache sunrpc joydev hid_generic usbhid usb_storage hid kvm_amd kvm crc32_pclmul ghash_clmulni_intel snd_hda_codec_ca0110 aesni_intel aes_x86_64 lrw gf128mul glue_helper ablk_helper evdev cryptd snd_hda_codec_hdmi snd_hda_codec_generic fam15h_power acpi_cpufreq snd_hda_intel snd_hda_controller pcspkr k10temp snd_hda_codec snd_hwdep psmouse serio_raw edac_mce_amd edac_core sp5100_tco processor button snd_pcm drm nuvoton_cir snd_timer rc_core snd soundcore shpchp i2c_piix4 i2c_core thermal_sys fuse parport_pc ppdev lp parport autofs4 ext4 crc16 mbcache jbd2 sr_mod cdrom sg ata_generic sd_mod crc_t10dif crct10dif_generic ohci_pci crct10dif_pclmul crct10dif_common crc32c_intel xhci
@vedranmiletic
vedranmiletic / gist:d6647cd4dbb47a46f14e
Created July 6, 2015 11:43
Clang 3.6 callback.h warning fix
diff --git a/src/core/model/callback.h b/src/core/model/callback.h
--- a/src/core/model/callback.h
+++ b/src/core/model/callback.h
@@ -1252,10 +1252,12 @@
void DoAssign (Ptr<const CallbackImplBase> other) {
if (!DoCheckType (other))
{
+ const CallbackImplBase * otherRaw = PeekPointer (other);
Ptr<CallbackImpl<R,T1,T2,T3,T4,T5,T6,T7,T8,T9> > expected;
+ CallbackImpl<R,T1,T2,T3,T4,T5,T6,T7,T8,T9> * expectedRaw = PeekPointer (expected);
@vedranmiletic
vedranmiletic / specify-modules.patch
Created September 29, 2015 13:42
Add -M option to test.py
diff --git a/test.py b/test.py
--- a/test.py
+++ b/test.py
@@ -1122,7 +1122,14 @@
example_names_original,
python_tests)
- for module in NS3_ENABLED_MODULES:
+ # User can specify which modules to test
+ if options.modules == "*":
@vedranmiletic
vedranmiletic / libclc-add-tonga.patch
Created December 10, 2015 19:40
Provide symlink to amdgcn LLVM IR bytecode for Tonga GPUs
diff --git a/configure.py b/configure.py
index 287f87f..93ff839 100755
--- a/configure.py
+++ b/configure.py
@@ -96,7 +96,7 @@ available_targets = {
{'gpu' : 'barts', 'aliases' : ['turks', 'caicos']},
{'gpu' : 'cayman', 'aliases' : ['aruba']}]},
'amdgcn--': { 'devices' :
- [{'gpu' : 'tahiti', 'aliases' : ['pitcairn', 'verde', 'oland', 'hainan', 'bonaire', 'kabini', 'kaveri', 'hawaii','mullins']}]},
+ [{'gpu' : 'tahiti', 'aliases' : ['pitcairn', 'verde', 'oland', 'hainan', 'bonaire', 'kabini', 'kaveri', 'hawaii', 'mullins', 'tonga']}]},
@vedranmiletic
vedranmiletic / gmx-OpenCL-kernel-AMD.ll
Created March 27, 2016 12:55
GROMACS OpenCL kernel for AMD in LLVM IR
This file has been truncated, but you can view the full file.
; ModuleID = 'input.cl'
target datalayout = "e-p:32:32-p1:64:64-p2:64:64-p3:32:32-p4:64:64-p5:32:32-p24:64:64-i64:64-v16:16-v24:32-v32:32-v48:64-v96:128-v192:256-v256:256-v512:512-v1024:1024-v2048:2048-n32:64"
target triple = "amdgcn--"
%struct.nbnxn_sci_t = type { i32, i32, i32, i32 }
%struct.nbnxn_cj4_t = type { [4 x i32], [2 x %struct.nbnxn_im_ei_t] }
%struct.nbnxn_im_ei_t = type { i32, i32 }
%struct.nbnxn_excl_t = type { [32 x i32] }
; Function Attrs: nounwind
[root@f1 ~]# SYSTEMD_LOG_LEVEL=debug systemd-tmpfiles --create --clean --remove
Reading config file "/usr/lib/tmpfiles.d/dnf.conf".
Reading config file "/usr/lib/tmpfiles.d/etc.conf".
Reading config file "/usr/lib/tmpfiles.d/home.conf".
Reading config file "/usr/lib/tmpfiles.d/initscripts.conf".
Reading config file "/usr/lib/tmpfiles.d/iscsi.conf".
Reading config file "/usr/lib/tmpfiles.d/journal-nocow.conf".
[/usr/lib/tmpfiles.d/journal-nocow.conf:26] Failed to replace specifiers: /var/log/journal/%m
Reading config file "/run/tmpfiles.d/kmod.conf".
Ignoring entry c! "/dev/autofs" because --boot is not specified.
execve("/usr/bin/systemd-tmpfiles", ["systemd-tmpfiles", "--create", "--clean", "--remove"], [/* 23 vars */]) = 0
brk(NULL) = 0x7f5f2000
uname({sysname="Linux", nodename="f1.miletic.net", ...}) = 0
mmap2(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xb6fe2000
access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or directory)
open("/usr/lib/systemd/tls/v7l/vfp/libsystemd-shared-231.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
stat64("/usr/lib/systemd/tls/v7l/vfp", 0xbedbbc18) = -1 ENOENT (No such file or directory)
open("/usr/lib/systemd/tls/v7l/libsystemd-shared-231.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
stat64("/usr/lib/systemd/tls/v7l", 0xbedbbc18) = -1 ENOENT (No such file or directory)
open("/usr/lib/systemd/tls/vfp/libsystemd-shared-231.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
This file has been truncated, but you can view the full file.
:-) GROMACS - gmx mdrun, 2016.2-dev-20170105-4feb0be (-:
GROMACS is written by:
Emile Apol Rossen Apostolov Herman J.C. Berendsen Par Bjelkmar
Aldert van Buuren Rudi van Drunen Anton Feenstra Gerrit Groenhof
Christoph Junghans Anca Hamuraru Vincent Hindriksen Dimitrios Karkoulis
Peter Kasson Jiri Kraus Carsten Kutzner Per Larsson
Justin A. Lemkul Magnus Lundborg Pieter Meulenhoff Erik Marklund
Teemu Murtola Szilard Pall Sander Pronk Roland Schulz
Alexey Shvetsov Michael Shirts Alfons Sijbers Peter Tieleman