This has moved to https://github.com/bitcoin/bitcoin/blob/master/doc/reduce-memory.md
このgistは Cloud Foundry Advent Calendar 2013 の16日目の記事です。
現在、CloudFoundryのComponentsはGo化しつつあります。それにより、Rubyで実装されていたものに対して性能向上していたり、ソースが読みやすくなっていたりする(こちらは主観ですが・・)半面、開発者にとっての課題も生まれています。その課題のひとつが__依存パッケージ管理__です。まずはRubyの外部パッケージ管理について簡単に振り返りつつ、Goのそれを見ていこうと思います。
Rubyでは外部パッケージはGemファイルとなっており、大抵の場合、Bundlerで管理します。また、最新版が動くとは限らないため設定ファイルにバージョンを指定してそれを使用します。Gemファイル自体はRubyGems.orgに置かれており、ここからダウンロードされます。
Goではソースコード中のimport句でパッケージを指定します。設定ファイルは使いません。以下に例を示します。
HTTP transfer protocols | |
======================= | |
Git supports two HTTP based transfer protocols. A "dumb" protocol | |
which requires only a standard HTTP server on the server end of the | |
connection, and a "smart" protocol which requires a Git aware CGI | |
(or server module). This document describes both protocols. | |
As a design feature smart clients can automatically upgrade "dumb" | |
protocol URLs to smart URLs. This permits all users to have the |
#include "tweetnacl.h" | |
#define FOR(i,n) for (i = 0;i < n;++i) | |
#define sv static void | |
typedef unsigned char u8; | |
typedef unsigned int u32; | |
typedef unsigned long long u64; | |
typedef long long i64; | |
typedef i64 gf[16]; |
-
xv6を学ぶ上での準備
-
起動処理を読む(main.c の main() が呼ばれるまで)
-
main() からmpmain()が呼ばれるまで
http://www.gnucitizen.org/blog/hacking-the-interwebs/ や、この問題を取り上げてるブログ記事なんかで | |
Flashの仕様じゃー、とかバージョンアップしても直らないみたいなこと書かれてるのですが、 | |
少なくとも現状、Flashで独自のリクエストヘッダ追加した上でのクロスドメインのPOSTリクエストはcrossdomain.xmlを要求するようになっています。 | |
Flashの仕様なんでバージョンアップしても解消しないんだぜー、って書かれたままの記事が多くあるため | |
「えっ、そうなの?」という印象を受けてしまった。 | |
この記事が書かれた頃には出来たようだけど、JavaScript使いからするとこの挙動は直感に反するもので、 | |
Flashを使うことで「ユーザーの許可無く」「ブラウザ標準の機能で出来ること以上のことが出来ている」のがおかしい。 |
Many users of Git are curious about the lack of delta compression at the object (blob) level when commits are first written. This efficiency is saved until the pack file is written. Loose objects are written in compressed, but non-delta format at the time of each commit.
A simple run though of a commit sequence with only the smallest change to the image (in uncompressed TIFF format to amplify the observable behavior) aids the understanding of this deferred and different approach efficiency.
Create the repo:
/* | |
* Parallel bitonic sort using CUDA. | |
* Compile with | |
* nvcc -arch=sm_11 bitonic_sort.cu | |
* Based on http://www.tools-of-computing.com/tc/CS/Sorts/bitonic_sort.htm | |
* License: BSD 3 | |
*/ | |
#include <stdlib.h> | |
#include <stdio.h> |