//===--- CGStmt.cpp - Emit LLVM Code from Statements ----------------------===////// The LLVM Compiler Infrastructure//// This file is distributed under the University of Illinois Open Source// License. See LICENSE.TXT for details.////===----------------------------------------------------------------------===////// This contains code to emit Stmt nodes as LLVM code.////===----------------------------------------------------------------------===//#include"CGDebugInfo.h"#include"CodeGenModule.h"#include"CodeGenFunction.h"#include"TargetInfo.h"#include"clang/AST/StmtVisitor.h"#include"clang/Basic/PrettyStackTrace.h"#include"clang/Basic/TargetInfo.h"#include"llvm/ADT/StringExtras.h"#include"llvm/InlineAsm.h"#include"llvm/Intrinsics.h"#include"llvm/Target/TargetData.h"usingnamespaceclang;usingnamespaceCodeGen;//===----------------------------------------------------------------------===//// Statement Emission//===----------------------------------------------------------------------===//voidCodeGenFunction::EmitStopPoint(constStmt*S){if(CGDebugInfo*DI=getDebugInfo()){if(isa<DeclStmt>(S))DI->setLocation(S->getLocEnd());elseDI->setLocation(S->getLocStart());DI->UpdateLineDirectiveRegion(Builder);DI->EmitStopPoint(Builder);}}voidCodeGenFunction::EmitStmt(constStmt*S){assert(S&&"Null statement?");// Check if we can handle this without bothering to generate an// insert point or debug info.if(EmitSimpleStmt(S))return;// Check if we are generating unreachable code.if(!HaveInsertPoint()){// If so, and the statement doesn't contain a label, then we do not need to// generate actual code. This is safe because (1) the current point is// unreachable, so we don't need t