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
eu ~/src/clever/benchmark $ sh run.sh | |
Running threads benchmark... | |
threads/threads_001.clv: | |
Time elapsed single-thread version clever: 2.31208 | |
Time elapsed multi-thread version clever: 1.55628 | |
Relative time difference: 32.6888 % | |
Result: 200000010000000 | |
[OK] | |
threads/threads_001.py: [python version] | |
Time elapsed single-thread python: 3.37006902695 |
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
eu ~/src/clever/benchmark $ sh run.sh | |
Running threads benchmark... | |
threads/threads_001.clv: | |
Time elapsed single-thread version clever: 2.30588 | |
Time elapsed multi-thread version clever: 1.54125 | |
Relative time difference: 33.1601 % | |
Result: 200000010000000 | |
[OK] | |
threads/threads_001.py: [python version] | |
Time elapsed single-thread python: 3.55690193176 |
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
eu ~/src/clever/benchmark $ sh run.sh | |
Running threads benchmark... | |
threads/threads_001.py: [python version] | |
Time elapsed single-thread python: 3.37238383293 | |
Time elapsed multi-thread python: 2.16011404991 | |
Relative time difference: 35.9469693569 % | |
Result: 200000010000000 | |
[OK] | |
threads/threads_001.lua: [lua version] | |
[OK] |
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 shorten_url(url,callback) { | |
var XHR = Titanium.Network.createHTTPClient({ | |
onload: function () { | |
try { | |
shorturl = JSON.parse(this.responseText); | |
shorturl = shorturl.id; | |
} catch(e) { | |
shorturl = 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
/* | |
* Local SQLite sync adapter which will store all models in | |
* an on device database | |
*/ | |
var _ = require('alloy/underscore')._, | |
db; | |
function S4() { | |
return (((1+Math.random())*0x10000)|0).toString(16).substring(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
pedro@FIOPREV2256-linux:~/src/clever$ cmake . | |
-- The C compiler identification is GNU | |
-- The CXX compiler identification is GNU | |
-- Check for working C compiler: /usr/bin/gcc | |
-- Check for working C compiler: /usr/bin/gcc -- works | |
-- Detecting C compiler ABI info | |
-- Detecting C compiler ABI info - done | |
-- Check for working CXX compiler: /usr/bin/c++ | |
-- Check for working CXX compiler: /usr/bin/c++ -- works | |
-- Detecting CXX compiler ABI info |
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
HTTP/1.1 200 OK | |
Server: nginx | |
Date: Mon, 26 Mar 2012 19:00:43 GMT | |
Content-Type: video/mp4 | |
Connection: keep-alive | |
X-Mod-H264-Streaming: version=2.2.7 | |
Content-Length: 42052720 | |
Last-Modified: Wed, 09 Jun 2010 03:46:06 GMT | |
Accept-Ranges: bytes | |
X-Edge-Id: 688143469 |
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
#!/Users/eu/src/clever/clever | |
import std; | |
import 'cleverfw.clv' as fw; | |
Map<String, Function<Int>> routesGet; | |
routesGet.insert("^sign_up$", Int () { | |
println("PLEASE, SIGN UP NOW!"); | |
return 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
import std; | |
extern "libcurl" { | |
FFIObject curl_easy_init(); | |
Int curl_easy_setopt(FFIObject handle, Int option, String param); | |
Int curl_easy_perform(FFIObject handle); | |
Void curl_easy_cleanup(FFIObject handle); | |
} | |
FFIObject c, r; |
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
import std; | |
extern libcurl { | |
FFIObject curl_easy_init(); | |
} | |
FFIObject c; | |
curl_easy_init(); |