This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH 1/8] [AArch64] Refactor aarch64_make_prologue_cache


Pierre Langlois <pierre.langlois@arm.com> writes:

>  static struct aarch64_prologue_cache *
> -aarch64_make_prologue_cache (struct frame_info *this_frame)
> +aarch64_make_prologue_cache (struct frame_info *this_frame, void
> **this_cache)

Could you document this function?  add comments about it, its
arguments, and return value.

>  {
>    struct aarch64_prologue_cache *cache;
>    CORE_ADDR unwound_fp;
>    int reg;
>  
> +  if (*this_cache)
> +    return *this_cache;
> +

Please check NULL explicitly, like if (*this_cache != NULL),  see
https://sourceware.org/gdb/wiki/Internals%20GDB-C-Coding-Standards

OK with these changes.

-- 
Yao (éå)


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]