Skip to content

Instantly share code, notes, and snippets.

View ivankelly's full-sized avatar

Ivan Kelly ivankelly

View GitHub Profile
@ivankelly
ivankelly / wtf-tenuring.patch
Last active June 2, 2017 09:35
tenuring-patch
diff -r b4bdf3484720 src/share/vm/gc_implementation/g1/g1ParScanThreadState.cpp
--- a/src/share/vm/gc_implementation/g1/g1ParScanThreadState.cpp Thu Jan 05 01:40:00 2017 +0000
+++ b/src/share/vm/gc_implementation/g1/g1ParScanThreadState.cpp Wed Jan 18 13:35:05 2017 +0100
@@ -40,7 +40,7 @@
_term_attempts(0),
_tenuring_threshold(g1h->g1_policy()->tenuring_threshold()),
_age_table(false), _scanner(g1h, rp),
- _strong_roots_time(0), _term_time(0) {
+ _strong_roots_time(0), _term_time(0), survivorAges() {
_scanner.set_par_scan_thread_state(this);
@ivankelly
ivankelly / gclog.md
Last active June 2, 2017 08:56
wtf-is-tenuring
73481.571: [GC pause (young)
Desired survivor size 524288000 bytes, new threshold 6 (max 6)
- age   1:    1990040 bytes,    1990040 total
- age   2:    1702416 bytes,    3692456 total
- age   3:    1698744 bytes,    5391200 total
- age   4:    1701408 bytes,    7092608 total
- age   5:    1700608 bytes,    8793216 total
- age   6:    1701408 bytes,   10494624 total
, 0.1204130 secs]
 [Parallel Time: 107.3 ms, GC Workers: 8]
> select time, max(value) from jvm_gc_G1YoungGeneration_CollectionCount where time > now() - 5d AND time > 1458340066997000000 group by build
name: jvm_gc_G1YoungGeneration_CollectionCount
tags: build=jenkins_core_base_perf_17
time max
---- ---
1458807954386596544 39
name: jvm_gc_G1YoungGeneration_CollectionCount
tags: build=jenkins_core_base_perf_18
@ivankelly
ivankelly / test_spotify.c
Last active December 17, 2015 06:19
Get a segfault with spotify
#include <stdio.h>
#include <libspotify/api.h>
#include <glib.h>
#include "tmpappkey.c"
sp_track* current_track = NULL;
int i = 0;
int test_spotify_music_delivery(sp_session *session, const sp_audioformat *format,
const void *frames, int num_frames) {
try {
cluster.transitionToActive(1); // This line is TestBookKeeperAsHASharedDir.java:241
fail("Shouldn't have been able to start two primaries"
+ " with single shared storage");
} catch (java.lang.IllegalStateException e) {
LOG.info("IKCheck1", e);
} catch (Throwable t) {
LOG.info("IKCheck", t);
//assertTrue(e.getMessage().contains("Cannot start writing at"));
#!/usr/local/bin/bash
for i in deps/*.jar; do
HADOOP_CLASSPATH=$HADOOP_CLASSPATH:$i
LIBJARS=$LIBJARS,$i
done
export HADOOP_CLASSPATH
export LIBJARS
(defun magit-refresh-diff-buffer (range args)
(let ((magit-current-diff-range (cond
((stringp range)
(cons range 'working))
((null (cdr range))
(cons (car range) 'working))
(t
range))))
(setq magit-current-range range)
(magit-create-buffer-sections
debugfs 1.39 (29-May-2006)
Inode: 190644897 Type: regular Mode: 0664 Flags: 0x0 Generation: 634347075
User: 56433 Group: 100 Size: 3741319680
File ACL: 190645639 Directory ACL: 0
Links: 1 Blockcount: 7306376
Fragment: Address: 0 Number: 0 Size: 0
ctime: 0x4ec1dca2 -- Tue Nov 15 03:29:38 2011
atime: 0x4ec1d7e2 -- Tue Nov 15 03:09:22 2011
mtime: 0x4ec1dca2 -- Tue Nov 15 03:29:38 2011
BLOCKS:
Running org.apache.hedwig.server.integration.TestHedwigRegion
java.net.ConnectException: Connection refused
at sun.nio.ch.SocketChannelImpl.checkConnect(Native Method)
at sun.nio.ch.SocketChannelImpl.finishConnect(SocketChannelImpl.java:574)
at org.jboss.netty.channel.socket.nio.NioClientSocketPipelineSink$Boss.connect(NioClientSocketPipelineSink.java:381)
at org.jboss.netty.channel.socket.nio.NioClientSocketPipelineSink$Boss.processSelectedKeys(NioClientSocketPipelineSink.java:351)
at org.jboss.netty.channel.socket.nio.NioClientSocketPipelineSink$Boss.run(NioClientSocketPipelineSink.java:273)
at org.jboss.netty.util.internal.IoWorkerRunnable.run(IoWorkerRunnable.java:53)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
<plugin>
<artifactId>maven-antrun-plugin</artifactId>
<executions>
<execution>
<id>generate-proto-sources</id>
<!-- <phase>generate-sources</phase> //-->
<configuration>
<tasks>
<mkdir dir="target/generated-sources/java" />
<mkdir dir="target/generated-sources/cpp" />