]> gcc.gnu.org Git - gcc.git/commit
gcov: Use system IO buffering marxin/heads/gcov-remove-io-buffering
authormarxin <mliska@suse.cz>
Wed, 18 Nov 2020 15:13:23 +0000 (16:13 +0100)
committerMartin Liska <mliska@suse.cz>
Wed, 17 Mar 2021 14:14:18 +0000 (15:14 +0100)
commitd3bb8f00cddf07d1f788aaabed7a52fd2cc5d87e
tree2f0959afc65279d65925f220f3312b2d23bd8b13
parent39916ceab4940315e84bcd966da2c1d4a8e1734b
gcov: Use system IO buffering

gcc/ChangeLog:

* gcov-io.c (gcov_write_block): Remove.
(gcov_write_words): Likewise.
(gcov_read_words): Re-implement using gcov_read_bytes.
(gcov_allocate): Remove.
(GCOV_BLOCK_SIZE): Likewise.
(struct gcov_var): Remove most of the fields.
(gcov_position): Implement with ftell.
(gcov_rewrite): Remove setting of start and offset fields.
(from_file): Re-format.
(gcov_open): Remove setbuf call. It should not be needed.
(gcov_close): Remove internal buffer handling.
(gcov_magic): Use __builtin_bswap32.
(gcov_write_counter): Use directly gcov_write_unsigned.
(gcov_write_string): Use direct fwrite and do not round
to 4 bytes.
(gcov_seek): Use directly fseek.
(gcov_write_tag): Use gcov_write_unsigned directly.
(gcov_write_length): Likewise.
(gcov_write_tag_length): Likewise.
(gcov_read_bytes): Use directly fread.
(gcov_read_unsigned): Use gcov_read_words.
(gcov_read_counter): Likewise.
(gcov_read_string): Use gcov_read_bytes.
* gcov-io.h (GCOV_WORD_SIZE): Adjust to reflect
that size is not in bytes, but words (4B).
(GCOV_TAG_FUNCTION_LENGTH): Likewise.
(GCOV_TAG_ARCS_LENGTH): Likewise.
(GCOV_TAG_ARCS_NUM): Likewise.
(GCOV_TAG_COUNTER_LENGTH): Likewise.
(GCOV_TAG_COUNTER_NUM): Likewise.
(GCOV_TAG_SUMMARY_LENGTH): Likewise.

libgcc/ChangeLog:

* libgcov-driver.c: Fix GNU coding style.
gcc/gcov-io.c
gcc/gcov-io.h
libgcc/libgcov-driver.c
This page took 0.067084 seconds and 6 git commands to generate.