docs(10_Wiki): 위키 전체 재구성 — Topic_* 폴더를 4개 카테고리로 통합 + 대규모 중복 제거

Topic_Agent/Topic_Blog/Topics/Topics_Biz/Topics_Meeting/Topics_Rag의 마크다운 지식 문서를
Topic_General/Topic_Programming/Topic_Graphic/Topic_Business 4개 카테고리로 재분류.

- 중복 제거: frontmatter의 status:duplicate/merged + duplicate_of/redirect_to 필드로
  자기 자신을 중복으로 선언한 리다이렉트 stub 1032개 제거, 완전 동일 내용 파일 472개 제거,
  동일 파일명·다른 내용 충돌 시 더 큰(완전한) 버전만 유지(162개 제거) — 총 1639개 중복 제거.
- 분류: 폴더 단위로 명확한 항목(AI_and_ML/Coding/Architecture 등 → Programming,
  Comfyui/Visual_Effects → Graphic, Topics_Biz/Topics_Meeting/사업 등 → Business,
  Poetic_Blog_Writing/창의성/Game_Design 등 → General)은 폴더 우선순위로,
  나머지 혼재 폴더(Topic_Agent/Topic_Blog/Topics 루트/Thinking & Reasoning/Other/UI_UX_Assets)는
  title/tags 키워드 스코어링으로 파일 단위 분류(불명확한 경우 General로 폴백).
  원본 폴더명은 "From_*" 서브폴더로 보존해 추적 가능성 유지.
- 최종 배치: Programming 2784 / General 1608 / Graphic 285 / Business 249 = 4926개 문서.
- 에이전트 운영 상태(.astra/.agent/.obsidian/sessions/memory/_company/docs/lessons/_shared/src)는
  지식 콘텐츠가 아니므로 재분류 대상에서 제외하고 원위치 유지.
- Topics/Topic_email(상위 보호 폴더 Topic_email과 파일명 100% 중복) 삭제 — 보호 폴더 자체는 미변경.
- 완전히 비게 된 Topic_Agent/Topic_Blog/Topics_Biz/Topics_Rag 폴더 제거.
This commit is contained in:
Antigravity Agent
2026-07-05 00:33:48 +09:00
parent 1cfd3bbb56
commit 9148c358d0
6455 changed files with 1 additions and 86875 deletions
@@ -0,0 +1,163 @@
---
id: wiki-2026-0508-hermes
title: Hermes
category: 10_Wiki/Topics
status: verified
canonical_id: self
aliases: [Hermes Engine, React Native Hermes, Hermes JS]
duplicate_of: none
source_trust_level: A
confidence_score: 0.9
verification_status: applied
tags: [react-native, javascript-engine, hermes, mobile]
raw_sources: []
last_reinforced: 2026-05-10
github_commit: pending
tech_stack:
language: cpp
framework: react-native
---
# Hermes
## 매 한 줄
> **"매 mobile 에 매 최적화된 매 ahead-of-time bytecode 매 JS engine."**. Meta 가 매 React Native 용으로 매 만든 engine. 매 startup time + 매 memory + 매 binary size 가 매 우선. 매 2026 의 매 RN 0.70+ 부터 매 default — 매 JSC 대비 매 cold start 30-50% 단축.
## 매 핵심
### 매 설계 목표
- **Fast startup**: 매 AOT bytecode → 매 parse 비용 0.
- **Low memory**: 매 generational GC, 매 NaN-boxing 없는 매 Hades collector (concurrent).
- **Small binary**: 매 SymbolTable / StringTable 의 매 dedupe.
- **Mobile first**: 매 ARM64 + 매 small heap 의 매 가정.
### 매 Architecture
- **Compiler**: hbc (Hermes ByteCode) — 매 build 시 매 .hbc 파일 생성.
- **VM**: register-based interpreter — 매 stack-based JSC 와 매 다름.
- **GC**: Hades — 매 concurrent + generational.
- **No JIT** (default): 매 mobile binary 정책 (iOS) + 매 startup 우선. 매 static Hermes (sh) 가 매 AOT native compile 실험.
### 매 vs JSC vs V8
| 항목 | Hermes | JSC | V8 |
|---|---|---|---|
| Startup | 매 빠름 (AOT) | 매 보통 | 매 느림 (parse + JIT) |
| Throughput | 매 낮음 (no JIT) | 매 보통 | 매 매우 높음 |
| Memory | 매 낮음 | 매 보통 | 매 높음 |
| 사용처 | RN | iOS Safari, RN (legacy) | Chrome, Node |
### 매 응용
1. RN app cold start 단축.
2. Bundle size 절감 (.hbc 가 .js 보다 작음).
3. 매 Hermes-specific debugger (Chrome DevTools 호환).
## 💻 패턴
### Enable in RN (already default in 0.70+)
```javascript
// android/app/build.gradle
project.ext.react = [
enableHermes: true,
hermesCommand: "../../node_modules/react-native/sdks/hermes/destroot/bin/hermesc",
]
// ios/Podfile
use_react_native!(
:path => config[:reactNativePath],
:hermes_enabled => true,
)
```
### Verify Hermes is running
```javascript
const isHermes = () => !!global.HermesInternal;
console.log('engine:', isHermes() ? 'Hermes' : 'JSC');
```
### Compile JS to bytecode (CLI)
```bash
hermesc -emit-binary -out=index.hbc index.js
# Inspect
hermes -dump-bytecode index.hbc
```
### Profile Hermes startup
```bash
# Sample profiler
hermes --sample-profiling -O index.js
# → output trace.json (Chrome DevTools profile format)
```
### Memory leak detection (Hermes-specific)
```javascript
// Heap snapshot
import { HermesInternal } from 'react-native';
const snap = HermesInternal?.getInstrumentedStats?.();
console.log(snap); // js_heapSize, js_allocatedBytes, ...
```
### Avoid Hermes pitfalls
```javascript
// 1. eval / new Function — supported but slow (no JIT)
// 2. Proxy — supported in 2026 but heavier than V8
// 3. Intl — opt-in (intl=true in build flag), default 작음
// Prefer static patterns
const handler = handlers[type]; // O(1) lookup
// over
const handler = eval(`handle_${type}`);
```
### Static Hermes (experimental 2026)
```bash
# AOT to native — bypass interpreter
shermes -typed -exec index.ts
# Significant throughput gain when types annotated
```
### Source map for Hermes bundle
```bash
react-native bundle \
--platform android \
--dev false \
--entry-file index.js \
--bundle-output index.android.bundle \
--sourcemap-output index.android.bundle.map \
--minify true
# Hermes ingests .map for symbolicated stack traces
```
## 매 결정 기준
| 상황 | Engine |
|---|---|
| 매 RN app | Hermes (default) |
| 매 cold start critical | Hermes |
| 매 heavy compute | JSC + worker / native module |
| 매 typed perf-critical RN | Static Hermes (experimental) |
| 매 web | V8 / JSC (browser native) |
**기본값**: Hermes ON. 매 RN 0.70+ 자동.
## 🔗 Graph
- 부모: [[React Native]]
- 변형: [[V8]] · [[JavaScriptCore]]
- Adjacent: [[Bytecode]] · [[GC]]
## 🤖 LLM 활용
**언제**: 매 RN startup 분석, 매 bundle size 최적화, 매 JS engine trade-off.
**언제 X**: 매 web — 매 browser engine 직접 제어 X.
## ❌ 안티패턴
- **eval 의존**: 매 JIT 없음 — 매 매우 느림.
- **Bundle 비분할**: 매 .hbc 1개 거대 — 매 RAM bundle / inline-requires 활용.
- **JSC 가정 코드**: 매 Symbol toPrimitive 등 매 corner case.
- **Hermes 끄고 RN**: 매 거의 매 lose-lose (2026 기준).
## 🧪 검증 / 중복
- Verified (hermesengine.dev, RN 0.74+ release notes).
- 신뢰도 A.
## 🕓 Changelog
| 날짜 | 변경 |
|---|---|
| 2026-05-08 | Phase 1 |
| 2026-05-10 | Manual cleanup — 매 Hermes architecture + RN integration |