View gcc default macro definition

Basic commands Execute the gcc -E -dM test.c command to view the default macro definition of gcc on the current system, where test.c is a c source file with empty content. Extension Embedded gcc can add CPU parameters to see the default macro definition of gcc under the current compilation configuration, for example, execute the […]

Principles of using eBPF in Android and examples of kprobe dmabuf_setup

Table of Contents eBPF in Android Android eBPF kprobe dma code Define a MAP Define a PROG bpfprogs/Android.bp test program bpfprogs/memstats/Android.bp bpfprogs/memstats/MemStats.h bpfprogs/memstats/MemStats.cpp bpfprogs/memstats/MemStatsMain.cpp Compile and run Result analysis summary eBPF in Android Official website: https://source.android.com/docs/core/architecture/kernel/bpf?hl=zh-cn#tracepoints The official Android website has a more detailed introduction. For official examples of using eBPF in Android, you can […]

Android JNI static and dynamic injection methods

Author: MiniCode One of the more popular ways for Android to call C/C++ code is through JNI. There are two ways to implement local methods: static and dynamic Create a C project or C Module: After successful creation, the following files (CMakeLists.txt, nativelib.cpp) will be generated: Among them: CMakeLists file is used to package cpp […]

Tree dp – a super practical data structure

? 1. Concept introduction Tree DP is dynamic programming based on trees as a model. Mainly use the substructure brought by the tree itself (the parent-child relationship on the tree) to perform state transfer. Generally, the DP value of the parent node is derived from the DP value of the child node. 2. Detailed explanation […]

javascript:void($=o),javascript void o

Hello everyone, the editor will answer the question of javascript:void($=o). Many people still don’t know javascript void o, let’s take a look at it now! JavaScript object-oriented (ES5 article) 1. JavaScript object-oriented 1. Several ways to create objects in JavaScript 1. 1. Constructor pattern 1. 2. Factory mode 1. 3. Prototype mode 1. 4. Combined […]

How to use vue-cli scaffolding to quickly deploy engineering projects

How to use vue-cli scaffolding to quickly deploy engineering projects Reason why engineering is needed: Modular development: Engineering allows developers to divide the entire project into small modules, each focusing on specific functions. This modular development makes code easier to organize, maintain, and reuse. Automated construction: Engineering tools can automatically perform tasks such as code […]

SpringCloud GateWay custom filter GatewayFilter and AbstractGatewayFactory

1. GatewayFilter GatewayFilter is a simple interface used to define the behavior of a gateway filter. A gateway filter is a class that implements the GatewayFilter interface and can perform certain operations when a request enters the gateway or when a response leaves the gateway. Filters can be used to modify requests or responses, log, […]