- Install Xcode (Avaliable on the Mac App Store)
- Install Xcode Command Line Tools (Preferences > Downloads)
- Install depot_tools
$ git clone https://chromium.googlesource.com/chromium/tools/depot_tools.git
$ nano ~/.zshrc
- Add
path=('/path/to/depot_tools' $path)
This file contains 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
var ko = require('knockout'); | |
ko.components.register('simple-name', require('./components/simple-name/simple-name.js')); | |
ko.applyBindings({ userName: ko.observable() }); |
This file contains 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
class Register { | |
constructor() { | |
this.routes = [] | |
} | |
regist(obj, k, fn) { | |
const _i = this.routes.find(function(el) { | |
if((el.key === k || el.key.toString() === k.toString()) | |
&& Object.is(el.obj, obj)) { | |
return el |
This file contains 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
int doubler(int x) { | |
return 2 * x; | |
} |
Some people have mentioned that memcpy
and memmove
functions are hot
when profiling some WebAssembly benchmarks. Some examples:
I've been looking at perf profiles for wasm unity benchmark a bit recently and see that some
This file contains 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
;; Convert this to add.wasm by running: | |
;; | |
;; wat2wasm add.wat -o add.wasm | |
;; | |
(module | |
(func (export "add") (param i32 i32) (result i32) | |
get_local 0 | |
get_local 1 | |
i32.add)) |