摘要:
调用栈:main() --> libsosrc.so中的soFunc--> main.out中的callBySo #include <stdlib.h> #include <dlfcn.h> #include <stdio.h> void callBySo() { printf("callBySo\ 阅读全文
摘要:
调用栈:main() --> libsosrc.so中的soFunc--> main.out中的callBySo #include <stdlib.h> #include <dlfcn.h> #include <stdio.h> void callBySo() { printf("callBySo\ 阅读全文
摘要:
代码示例: #include <stdio.h> #include <stdlib.h> #include <dlfcn.h> typedef int(*Func)(void*); int callFunc(dtInterp_t a) { void* handle = dlopen("*.so", 阅读全文
摘要:
编译选项: CXXFLAGS += -mavx2 #include <immintrin.h> #include <cmath> void reset_xy(int *x, int *y, int vector_size) { for (int i = 0; i < vector_size; i++ 阅读全文
摘要:
window11截图快捷键: Win+Shift+S 显示乱码: 设置 -> 区域 -> 相关设置 -> 区域 -> 更改系统区域设置 -> 中文 阅读全文
摘要:
.vimrc: " add by school1024.com set ts=4 set softtabstop=4 set shiftwidth=4 set expandtab set autoindent TAB替换为空格 :set ts=4 :set expandtab :%retab! 空格 阅读全文
摘要:
VScode使用: VScode搭建C/C++开发环境 - 知乎 (zhihu.com) Visual studio使用: 添加文件夹(要求所有的文件必须在解决方案的目录中): 插件离线安装 1.下载.vsix文件 https://marketplace.visualstudio.com/vscod 阅读全文
摘要:
1、多线程 std::thread C++11之前链接需要-lpthread,之后引入多线程,不再需要第三方库。 函数指针、类函数指针、函数对象、lambda表达式作为线程函数传入std::thread构造示例后,线程立刻开始执行。 存储参数类似std::bind(),但是不同于std::funct 阅读全文
摘要:
查找某个目录下所有的文件内容: find src/ -type f -name "*.cpp" | xargs grep "test" 测试磁盘速度 time dd if=/dev/zero of=./test.dbf bs=8k count=300000 grep grep -r --exclud 阅读全文
摘要:
ubuntu下使用PageUp/PageDown快速翻出历史命令 #vim/etc/inputrc 解除两行注视后重启终端 "\e[5~": history-search-backward "\e[6~": history-search-forward 阅读全文
摘要:
1. 修改git默认的编辑器nano为vim的两种方法 git config --global core.editor vim .git/config文件,在[core]中添加 editor = vim 2. 忽略权限的diff git status一片红色,往往只是因为文件的读写执行权限发生了变化 阅读全文
|