valgrind --tool=cachegrind ./a.out
cg_annotate cachegrind.out.* --auto=yes- Ir: number of instructions executed
- I1mr: I1 cache read misses
valgrind --tool=cachegrind ./a.out
cg_annotate cachegrind.out.* --auto=yes| { | |
| "kind": "webfonts#webfontList", | |
| "items": [ | |
| { | |
| "kind": "webfonts#webfont", | |
| "family": "ABeeZee", | |
| "category": "sans-serif", | |
| "variants": [ | |
| "regular", | |
| "italic" |
| #include <time.h> | |
| #include <stdio.h> | |
| #include <vector> | |
| struct A { | |
| int mem[100]; | |
| }; | |
| int n = 1000000; |
| #pragma once | |
| /** | |
| \file minimalOpenGL/teapot.h | |
| \author Morgan McGuire, http://graphics.cs.williams.edu | |
| Geometric data for the Utah teapot. | |
| Distributed with the G3D Innovation Engine http://g3d.cs.williams.edu | |
| */ | |
| namespace Teapot { |
| #include <iostream> | |
| #include <ctime> | |
| #include <string> | |
| void function_a(const std::string& str) { | |
| return; | |
| } | |
| void function_b(std::string str) { | |
| return; |
| #ifdef GL_ES | |
| precision mediump float; | |
| #endif | |
| #define PI 3.14159265359 | |
| uniform vec2 u_resolution; | |
| uniform vec2 u_mouse; | |
| uniform float u_time; |
| global operator new | |
| global operator new [] | |
| global operator delete | |
| global operator delete [] | |
| #undef new | |
| void *operator new (size_t size, char *file, int line, char *function); | |
| // [...] | |
| #define new new (__FILE__, __LINE__, __FUNCTION__) |
| #include <iostream> | |
| #include <string> | |
| #include <cmath> | |
| void bCurveP4Derivative(float t, float p0x, float p0y, float p1x, float p1y, float p2x, float p2y, float p3x, float p3y, float* x, float* y) { | |
| // derivate of cubic b-curve is a quadratic b-curve | |
| float it = 1 - t; | |
| float f0 = 3 * powf(it, 2.f); | |
| float f1 = 6 * t * (it); | |
| float f2 = 3 * powf(t, 2.f); |