X-Git-Url: http://nsz.repo.hu/git/?a=blobdiff_plain;f=ir%2Fbe%2Fbeemitter.c;h=344d4a69344ab58e1ebd354430d90867ec75d6e4;hb=e1bfe8d072410f6ca115452bf9c1e3131fa27f4d;hp=2111b84a571fe072dc49d44d982560f31dda0f54;hpb=2adf84106c02caf097c2d6cf1764706bdc437bcc;p=libfirm diff --git a/ir/be/beemitter.c b/ir/be/beemitter.c index 2111b84a5..344d4a693 100644 --- a/ir/be/beemitter.c +++ b/ir/be/beemitter.c @@ -1,16 +1,37 @@ /* - * Author: Matthias Braun - * Date: 12.03.2007 - * Copyright: (c) Universitaet Karlsruhe - * License: This file is protected by GPL - GNU GENERAL PUBLIC LICENSE. + * Copyright (C) 1995-2007 University of Karlsruhe. All right reserved. + * + * This file is part of libFirm. + * + * This file may be distributed and/or modified under the terms of the + * GNU General Public License version 2 as published by the Free Software + * Foundation and appearing in the file LICENSE.GPL included in the + * packaging of this file. + * + * Licensees holding valid libFirm Professional Edition licenses may use + * this file in accordance with the libFirm Commercial License. + * Agreement provided with the Software. + * + * This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE + * WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR + * PURPOSE. + */ + +/** + * @file + * @brief Interface for assembler output. + * @author Matthias Braun + * @date 12.03.2007 + * @version $Id$ */ #ifdef HAVE_CONFIG_H #include "config.h" #endif #include "beemitter.h" -#include "xmalloc.h" #include "irprintf.h" +#include "ident.h" +#include "tv.h" void be_emit_init_env(be_emit_env_t *env, FILE *F) { @@ -34,6 +55,14 @@ void be_emit_ident(be_emit_env_t *env, ident *id) be_emit_string_len(env, str, len); } +void be_emit_tarval(be_emit_env_t *env, tarval *tv) +{ + char buf[64]; + + tarval_snprintf(buf, sizeof(buf), tv); + be_emit_string(env, buf); +} + void be_emit_irvprintf(be_emit_env_t *env, const char *fmt, va_list args) { char buf[256];