<commit_before>/*
 * Copyright (c) 2012-2016 <NAME>
 * See LICENSE for details.
 *
 * <NAME> <<EMAIL>>
 */

#include <stdlib.h>

#include <vdp1.h>
#include <vdp2.h>
#include <vdp2/tvmd.h>
#include <vdp2/vram.h>

#include <cons.h>

void __noreturn
internal_exception_show(const char *buffer)
{
        /* Reset the VDP1 */
        vdp1_init();

        /* Reset the VDP2 */
        vdp2_init();
        vdp2_tvmd_display_res_set(TVMD_INTERLACE_NONE, TVMD_HORZ_NORMAL_A,
            TVMD_VERT_224);
        vdp2_scrn_back_screen_color_set(VRAM_ADDR_4MBIT(0, 0x01FFFE),
            COLOR_RGB555(0, 7, 0));
        vdp2_tvmd_display_set();

        cons_init(CONS_DRIVER_VDP2, 40, 28);
        cons_buffer(buffer);

        vdp2_tvmd_vblank_out_wait();
        vdp2_tvmd_vblank_in_wait();
        vdp2_commit();
        cons_flush();

        abort();
}<commit_msg>Hide VDP1 even if FB hasn't been erased and changed<commit_after>/*
 * Copyright (c) 2012-2016 <NAME>
 * See LICENSE for details.
 *
 * <NAME> <<EMAIL>>
 */

#include <stdlib.h>

#include <vdp1.h>
#include <vdp2.h>
#include <vdp2/tvmd.h>
#include <vdp2/vram.h>

#include <cons.h>

void __noreturn
internal_exception_show(const char *buffer)
{
        /* Reset the VDP1 */
        vdp1_init();

        /* Reset the VDP2 */
        vdp2_init();
        vdp2_tvmd_display_res_set(TVMD_INTERLACE_NONE, TVMD_HORZ_NORMAL_A,
            TVMD_VERT_224);
        vdp2_scrn_back_screen_color_set(VRAM_ADDR_4MBIT(0, 0x01FFFE),
            COLOR_RGB555(0, 7, 0));

        /* Set sprite to type 0 and set its priority to 0 (invisible) */
        vdp2_sprite_type_set(0);
        vdp2_sprite_priority_set(0, 0);

        vdp2_tvmd_display_set();

        cons_init(CONS_DRIVER_VDP2, 40, 28);
        cons_buffer(buffer);

        vdp2_tvmd_vblank_out_wait();
        vdp2_tvmd_vblank_in_wait();
        vdp2_commit();
        cons_flush();

        abort();
}
{'fraction_non_alphanumeric': 0.12264150943396226, 'fraction_numerical': 0.04716981132075472, 'mean_word_length': 2.7212475633528266, 'pattern_counts': {'":': 0, '<': 23, '<?xml version=': 0, '>': 23, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '919217', 'n_tokens_mistral': 813, 'n_tokens_neox': 756, 'n_words': 132}