This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <ctime> | |
class Timer | |
{ | |
public: | |
Timer() { clock_gettime(CLOCK_REALTIME, &beg_); } | |
double elapsed() { | |
clock_gettime(CLOCK_REALTIME, &end_); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<script src="http://documentcloud.github.com/underscore/underscore-min.js"></script> | |
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js"></script> | |
<meta charset=utf-8 /> | |
<title>JS Bin</title> | |
<style id="jsbin-css"> | |
body { | |
font-family: sans-serif; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
From e3e7aa2249984e409f077732ee8cd95ff656f2a5 Mon Sep 17 00:00:00 2001 | |
From: Ian Link <Ian@Angler.(none)> | |
Date: Mon, 10 Jun 2013 23:19:07 -0700 | |
Subject: [PATCH 1/3] added separate limit for fastgin memory | |
--- | |
src/backend/access/gin/ginfast.c | 3 ++- | |
src/backend/utils/init/globals.c | 1 + | |
src/backend/utils/misc/guc.c | 12 ++++++++++++ | |
src/include/miscadmin.h | 1 + |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- create and populate a table with a GIN-indexable column | |
-- we pre-populate it to a large size; autovacuum kicks in when more than | |
-- a configured proportion of the table is newly inserted, and we want to | |
-- model the case where that doesn't happen often | |
drop table gtst; | |
create table gtst as | |
select array[i,j,i*j] as a | |
from generate_series(1,1000) i, generate_series(1,1000) j; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
From e3e7aa2249984e409f077732ee8cd95ff656f2a5 Mon Sep 17 00:00:00 2001 | |
From: Ian Link <Ian@Angler.(none)> | |
Date: Mon, 10 Jun 2013 23:19:07 -0700 | |
Subject: [PATCH] added separate limit for fastgin memory | |
--- | |
src/backend/access/gin/ginfast.c | 3 ++- | |
src/backend/utils/init/globals.c | 1 + | |
src/backend/utils/misc/guc.c | 12 ++++++++++++ | |
src/include/miscadmin.h | 1 + |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
window.addEventListener('load', function() { | |
var section = document.querySelector('div.main'), | |
args = document.querySelector('div.arguments'), | |
controls = document.querySelector('.controls'), | |
image = args.querySelector('img'), | |
video = args.querySelector('video'), | |
log = $('log'), | |
useBloomX = true, | |
useBloomY = true, | |
useBlending = true; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
window.addEventListener('load', function() { | |
var section = document.querySelector('div.main'), | |
args = document.querySelector('div.arguments'), | |
controls = document.querySelector('.controls'), | |
image = args.querySelector('img'), | |
video = args.querySelector('video'), | |
log = $('log'), | |
useBloomX = true, | |
useBloomY = true, | |
useBlending = true; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function setup_orientation(){ | |
function is_landscape(){ | |
if($(window).width() >= $(window).height()){ | |
return true; | |
} else { | |
return false; | |
} | |
} | |
var landscape = false; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function make_hsl(h,s,l){ | |
return "hsl("+h+","+s+"%,"+l+"%)"; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/*------------------------------------------------------------------------------------ | |
* | |
* Bind from JSON - uses JSON to set up UI bindings. Utilizes jquery's 'bind' | |
* | |
* Usage: | |
* Supply JSON file formatted like this: | |
* var json = [{ | |
* 'selector' : '#id', | |
* 'bind_to' : 'click', | |
* 'func' : [ |